Skip to content

Commit

Permalink
Update tests after location definition change for rules and vars
Browse files Browse the repository at this point in the history
  • Loading branch information
antoinepouille committed Sep 4, 2024
1 parent 289d994 commit 9f0f84e
Show file tree
Hide file tree
Showing 69 changed files with 684 additions and 678 deletions.
2 changes: 1 addition & 1 deletion tests/integration/CMSB_paper/dimer/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
2 changes: 1 addition & 1 deletion tests/integration/CMSB_paper/dimer_cm_views/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
2 changes: 1 addition & 1 deletion tests/integration/CMSB_paper/dimer_views/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule obs (File "../dimer.ka", line 13, characters 5-39:) will never be applied.
rule obs (File "../dimer.ka", line 13, characters 0-39:) will never be applied.
------------------------------------------------------------
every agent may occur in the model

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ every agent may occur in the model
------------------------------------------------------------
The following transitions are separating:

* rule c (File "sep_transitions1.ka", line 5, characters 3-23:):
* rule c (File "sep_transitions1.ka", line 5, characters 0-23:):
A(z~u) -> A(z~p)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ every agent may occur in the model
------------------------------------------------------------
The following transitions are separating:

* rule z (File "sep_transitions2.ka", line 6, characters 3-23:):
* rule z (File "sep_transitions2.ka", line 6, characters 0-23:):
A(x~p,y~u,z~u) -> A(x~p,y~u,z~p)
A(x~u,y~u,z~u) -> A(x~u,y~u,z~p)

Expand Down
8 changes: 7 additions & 1 deletion tests/integration/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# To run this not through the repo root Makefile, please provide the $KAPPABIN path
OUTPUT_PATH:=output
ERROR:=error

Expand All @@ -17,7 +18,10 @@ help:
@echo 'make svg: recursively build all svg from existing dot files'
@echo 'make clean: recursively clean everything but the reference files'
@echo 'make clean_all: recursively clean everything including the reference files'
@echo
@echo 'To run this from this directory and not from the root Makefile, please specify the KAPPABIN path in the environment.'

# Run `README` scripts and generate `LOG`s and `error.log`s
%/$(OUTPUT_PATH)/LOG: %/README #$(shell which "$(KAPPABIN)KaSim") $(shell which "$(KAPPABIN)KaSa")
@[ -d $(dir $<)$(OUTPUT_PATH) ] || mkdir $(dir $<)$(OUTPUT_PATH)
@find $(dir $<)$(OUTPUT_PATH) -mindepth 1 \( -not -name \*.ref \) -delete
Expand All @@ -42,6 +46,7 @@ help:
diff -q $(basename $@).ref - || true
diff -u $(basename $@).ref - > $@ || true

# Run the scripts and compare the outputs by generating `%.diff`s
%/$(ERROR): %/$(OUTPUT_PATH)/LOG
@rm -f $@
@+$(MAKE) $$(find $(dir $@)$(OUTPUT_PATH) \( -not -type d -and -not -name \*.diff.\* \) -print \
Expand All @@ -56,9 +61,10 @@ error: $(DIRS_OF_TEST:=/$(ERROR))

all: error
@if [ -s $< ] ; then \
if [ $$(cat $< | wc -l) -gt 1500 ] ; then echo "Error file too big" ; else cat $< ; fi && exit 2 ; \
if [ $$(cat $< | wc -l) -gt 1500 ] ; then echo "Some tests FAILED, but output is NOT DISPLAYED because its size exceeds limit." ; else cat $< ; fi && exit 2 ; \
else echo "No difference has been found" ; fi

# Generate the `.ref` files from the current version of Kappa
build:
@+$(MAKE) clean_all
@+$(MAKE) $(DIRS_OF_TEST:=/$(OUTPUT_PATH)/LOG)
Expand Down
4 changes: 2 additions & 2 deletions tests/integration/influence_map/add_remove/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule label (File "add_remove.ka", line 4, characters 8-62:) will never be applied.
rule label (File "add_remove.ka", line 4, characters 0-62:) will never be applied.
rule File "add_remove.ka", line 5, characters 0-28: will never be applied.
rule File "add_remove.ka", line 6, characters 0-28: will never be applied.
rule File "add_remove.ka", line 7, characters 0-28: will never be applied.
Expand Down Expand Up @@ -48,7 +48,7 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule label (File "add_remove.ka", line 4, characters 8-62:) will never be applied.
rule label (File "add_remove.ka", line 4, characters 0-62:) will never be applied.
rule File "add_remove.ka", line 5, characters 0-28: will never be applied.
rule File "add_remove.ka", line 6, characters 0-28: will never be applied.
rule File "add_remove.ka", line 7, characters 0-28: will never be applied.
Expand Down
10 changes: 5 additions & 5 deletions tests/integration/influence_map/bound_to_unknown/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -314,11 +314,11 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule r1 (File "bound_to.ka", line 4, characters 5-33:) will never be applied.
rule r2 (File "bound_to.ka", line 5, characters 5-43:) will never be applied.
rule r3 (File "bound_to.ka", line 6, characters 5-43:) will never be applied.
rule r4 (File "bound_to.ka", line 7, characters 5-43:) will never be applied.
rule r5 (File "bound_to.ka", line 8, characters 5-29:) will never be applied.
rule r1 (File "bound_to.ka", line 4, characters 0-33:) will never be applied.
rule r2 (File "bound_to.ka", line 5, characters 0-43:) will never be applied.
rule r3 (File "bound_to.ka", line 6, characters 0-43:) will never be applied.
rule r4 (File "bound_to.ka", line 7, characters 0-43:) will never be applied.
rule r5 (File "bound_to.ka", line 8, characters 0-29:) will never be applied.

------------------------------------------------------------
* There are some non creatable agents
Expand Down
8 changes: 4 additions & 4 deletions tests/integration/influence_map/labels/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,10 @@ Reachability analysis...
------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule veryveryveryveryverylonglonglonglabel (File "labels.ka", line 3, characters 40-68:) will never be applied.
rule otherotherveryveryveryverylonglabel (File "labels.ka", line 4, characters 38-66:) will never be applied.
rule "0 (File "labels.ka", line 5, characters 5-33:) will never be applied.
rule \0 (File "labels.ka", line 6, characters 5-33:) will never be applied.
rule veryveryveryveryverylonglonglonglabel (File "labels.ka", line 3, characters 0-68:) will never be applied.
rule otherotherveryveryveryverylonglabel (File "labels.ka", line 4, characters 0-66:) will never be applied.
rule "0 (File "labels.ka", line 5, characters 0-33:) will never be applied.
rule \0 (File "labels.ka", line 6, characters 0-33:) will never be applied.

------------------------------------------------------------
* There are some non creatable agents
Expand Down
4 changes: 2 additions & 2 deletions tests/integration/influence_map/wild_cards/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -145,13 +145,13 @@ Refining the influence map...
Influence_map: The notation [i -> j] means an agent at position [i] of the first rule/var has an influence to an agent at position [j] of the second rule/var.
Reachability analysis...

Applying rule r1 (File "wild_cards.ka", line 5, characters 5-68:):
Applying rule r1 (File "wild_cards.ka", line 5, characters 0-68:):
the precondition is not satisfied yet

------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule r1 (File "wild_cards.ka", line 5, characters 5-68:) will never be applied.
rule r1 (File "wild_cards.ka", line 5, characters 0-68:) will never be applied.

------------------------------------------------------------
* There are some non creatable agents
Expand Down
42 changes: 21 additions & 21 deletions tests/integration/kasa_preprocessing/abc/output/LOG.ref
Original file line number Diff line number Diff line change
Expand Up @@ -673,10 +673,10 @@ EXTENSIONAL DESCRIPTION:
C(x1{u},x2{u},x1[.],x2[.])


Applying rule a.b (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

rule a.b (File "abc.ka", line 10, characters 6-64:) is applied for the first time
rule a.b (File "abc.ka", line 10, characters 0-64:) is applied for the first time

Updating the views for A(x[],c[])

Expand Down Expand Up @@ -728,19 +728,19 @@ EXTENSIONAL DESCRIPTION:
B(x[x.A])


Applying rule a.b_op (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b_op (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

rule a.b_op (File "abc.ka", line 10, characters 6-64:) is applied for the first time
rule a.b_op (File "abc.ka", line 10, characters 0-64:) is applied for the first time

Updating the views for A(x[],c[])

Updating the views for B(x[])

Applying rule ab.c (File "abc.ka", line 12, characters 7-71:):
Applying rule ab.c (File "abc.ka", line 12, characters 0-71:):
the precondition is satisfied

rule ab.c (File "abc.ka", line 12, characters 7-71:) is applied for the first time
rule ab.c (File "abc.ka", line 12, characters 0-71:) is applied for the first time

Updating the views for A(x[],c[])

Expand Down Expand Up @@ -822,10 +822,10 @@ EXTENSIONAL DESCRIPTION:
C(x1{u},x2{u},x1[c.A],x2[.])


Applying rule mod x1 (File "abc.ka", line 13, characters 9-64:):
Applying rule mod x1 (File "abc.ka", line 13, characters 0-64:):
the precondition is satisfied

rule mod x1 (File "abc.ka", line 13, characters 9-64:) is applied for the first time
rule mod x1 (File "abc.ka", line 13, characters 0-64:) is applied for the first time

Updating the views for C(x1{},x2{},x1[],x2[])

Expand Down Expand Up @@ -879,10 +879,10 @@ EXTENSIONAL DESCRIPTION:

Updating the views for A(x[],c[])

Applying rule a.c (File "abc.ka", line 14, characters 6-88:):
Applying rule a.c (File "abc.ka", line 14, characters 0-88:):
the precondition is satisfied

rule a.c (File "abc.ka", line 14, characters 6-88:) is applied for the first time
rule a.c (File "abc.ka", line 14, characters 0-88:) is applied for the first time

Updating the views for A(x[],c[])

Expand Down Expand Up @@ -964,10 +964,10 @@ EXTENSIONAL DESCRIPTION:
C(x1{p},x2{u},x1[.],x2[c.A])


Applying rule mod x2 (File "abc.ka", line 15, characters 9-92:):
Applying rule mod x2 (File "abc.ka", line 15, characters 0-92:):
the precondition is satisfied

rule mod x2 (File "abc.ka", line 15, characters 9-92:) is applied for the first time
rule mod x2 (File "abc.ka", line 15, characters 0-92:) is applied for the first time

Updating the views for A(x[],c[])

Expand Down Expand Up @@ -1021,7 +1021,7 @@ EXTENSIONAL DESCRIPTION:
C(x1{p},x2{p},x1[.],x2[.])


Applying rule a.b (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

Updating the views for A(x[],c[])
Expand Down Expand Up @@ -1056,14 +1056,14 @@ EXTENSIONAL DESCRIPTION:

Updating the views for B(x[])

Applying rule ab.c (File "abc.ka", line 12, characters 7-71:):
Applying rule ab.c (File "abc.ka", line 12, characters 0-71:):
the precondition is satisfied

Updating the views for A(x[],c[])

Updating the views for C(x1{},x2{},x1[],x2[])

Applying rule a.b_op (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b_op (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

Updating the views for A(x[],c[])
Expand Down Expand Up @@ -1098,42 +1098,42 @@ EXTENSIONAL DESCRIPTION:

Updating the views for B(x[])

Applying rule mod x1 (File "abc.ka", line 13, characters 9-64:):
Applying rule mod x1 (File "abc.ka", line 13, characters 0-64:):
the precondition is satisfied

Updating the views for C(x1{},x2{},x1[],x2[])

Updating the views for A(x[],c[])

Applying rule a.c (File "abc.ka", line 14, characters 6-88:):
Applying rule a.c (File "abc.ka", line 14, characters 0-88:):
the precondition is satisfied

Updating the views for A(x[],c[])

Updating the views for C(x1{},x2{},x1[],x2[])

Applying rule mod x2 (File "abc.ka", line 15, characters 9-92:):
Applying rule mod x2 (File "abc.ka", line 15, characters 0-92:):
the precondition is satisfied

Updating the views for A(x[],c[])

Updating the views for C(x1{},x2{},x1[],x2[])

Applying rule a.b (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

Updating the views for A(x[],c[])

Updating the views for B(x[])

Applying rule ab.c (File "abc.ka", line 12, characters 7-71:):
Applying rule ab.c (File "abc.ka", line 12, characters 0-71:):
the precondition is satisfied

Updating the views for A(x[],c[])

Updating the views for C(x1{},x2{},x1[],x2[])

Applying rule a.b_op (File "abc.ka", line 10, characters 6-64:):
Applying rule a.b_op (File "abc.ka", line 10, characters 0-64:):
the precondition is satisfied

Updating the views for A(x[],c[])
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,14 +171,14 @@ Influence_map:Inhibition_map:rule(1):'remove' A(x[.]),A(x[.]),.,.->A(x[.]),.,B(x
Influence_map:Inhibition_map:rule(1):'remove' A(x[.]),A(x[.]),.,.->A(x[.]),.,B(x[.]),A(x[.]) -> rule(1):'remove' A(x[.]),A(x[.]),.,.->A(x[.]),.,B(x[.]),A(x[.])[1->0]
Reachability analysis...

Applying rule remove (File "agent_order.ka", line 6, characters 9-61:):
Applying rule remove (File "agent_order.ka", line 6, characters 0-61:):
the precondition is not satisfied yet

------------------------------------------------------------
* There are some non applyable rules
------------------------------------------------------------
rule bind (File "agent_order.ka", line 5, characters 7-45:) will never be applied.
rule remove (File "agent_order.ka", line 6, characters 9-61:) will never be applied.
rule bind (File "agent_order.ka", line 5, characters 0-45:) will never be applied.
rule remove (File "agent_order.ka", line 6, characters 0-61:) will never be applied.

------------------------------------------------------------
* There are some non creatable agents
Expand Down
Loading

0 comments on commit 9f0f84e

Please sign in to comment.