Skip to content

Commit

Permalink
#5 use newest jqa snapshot, try out rules in adoc
Browse files Browse the repository at this point in the history
  • Loading branch information
JensNercheKE committed Oct 15, 2015
1 parent 9ffa136 commit 9df269b
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 2 deletions.
4 changes: 3 additions & 1 deletion build.gradle
Expand Up @@ -3,7 +3,7 @@ apply plugin: 'maven'
apply plugin: 'org.asciidoctor.gradle.asciidoctor'
apply plugin: 'com.github.jruby-gradle.base'

project.ext["jqaversion"] = "1.0.0"
project.ext["jqaversion"] = "1.1.0-RC2-SNAPSHOT"
project.group = 'de.kontext-e.jqassistant.plugin'
project.version = '1.1.0-SNAPSHOT'

Expand Down Expand Up @@ -47,6 +47,7 @@ subprojects {

repositories {
mavenCentral()
mavenLocal()
}

dependencies {
Expand Down Expand Up @@ -155,6 +156,7 @@ dependencies {
runtime("com.buschmais.jqassistant.plugin:jqassistant.plugin.javaee6:${project.jqaversion}")
runtime("com.buschmais.jqassistant.plugin:jqassistant.plugin.jaxrs:${project.jqaversion}")
runtime("com.buschmais.jqassistant.plugin:jqassistant.plugin.jpa2:${project.jqaversion}")
runtime("com.buschmais.jqassistant.plugin:jqassistant.plugin.junit:${project.jqaversion}")

runtime("de.kontext-e.jqassistant.plugin:jqassistant.plugin.checkstyle:${project.version}")
runtime("de.kontext-e.jqassistant.plugin:jqassistant.plugin.findbugs:${project.version}")
Expand Down
4 changes: 3 additions & 1 deletion doc/architecture/05_building_block_view.adoc
Expand Up @@ -7,7 +7,9 @@
[source, cypher, role=constraint, depends=junit4:TestClass, severity=blocker]
----
MATCH
(t)
(t:Junit4:Test:Class)
WHERE NOT
t.name =~ ".*Test"
RETURN
t AS InvalidTestClass
----
Expand Down
37 changes: 37 additions & 0 deletions doc/architecture/default_group.xml
@@ -0,0 +1,37 @@
<jqa:jqassistant-rules xmlns:jqa="http://www.buschmais.com/jqassistant/core/analysis/rules/schema/v1.0">

<constraint id="debug:rule" severity="critical">
<requiresConcept refId="dependency:Package"/>
<description>For debugging purposes</description>
<cypher><![CDATA[
match
(g:PlantUmlPackage)
return
g
]]></cypher>
</constraint>

<constraint id="dependency:WrongDirection" severity="critical">
<requiresConcept refId="dependency:Package"/>
<description>Finds package dependencies which are in the wrong direction according to the documentation.</description>
<cypher><![CDATA[
MATCH
(p1:PlantUmlPackage)-[:MAY_DEPEND_ON]->(p2:PlantUmlPackage),
(p3:Package)-[:DEPENDS_ON]->(p4:Package)
WHERE
p1.fqn = p4.fqn
AND p2.fqn = p3.fqn
RETURN
p3.fqn + "-->" + p4.fqn AS WrongDirection;
]]></cypher>
</constraint>

<group id="default">
<includeConstraint refId="dependency:WrongDirection" severity="critical"/>
<includeConstraint refId="naming-rules:TestsMustEndWithTest" severity="critical"/>
<!--
<includeConstraint refId="debug:rule" severity="info"/>
-->
</group>

</jqa:jqassistant-rules>

0 comments on commit 9df269b

Please sign in to comment.