Skip to content

Commit

Permalink
apply PR review
Browse files Browse the repository at this point in the history
  • Loading branch information
TannazVhdBMWExt committed Feb 3, 2025
1 parent 704aba9 commit 8dafc12
Show file tree
Hide file tree
Showing 9 changed files with 72 additions and 67 deletions.
10 changes: 7 additions & 3 deletions tests-integration/projects/coverage-half/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,16 @@ PYTHONPATH:=$(wildcard $(LOBSTER_ROOT)/test_install/lib/python*/site-packages)

THIS_TEST:=$(shell realpath --relative-to $(LOBSTER_ROOT) $(PWD))
THIS_TEST_ESCAPED:=$(subst /,\\/,$(THIS_TEST))
REFERENCE_OUTPUT:=report.reference_output

html_report.html: softreq.lobster sysreq.lobster lobster.conf trlc-softreq.conf trlc-sysreq.conf
@lobster-report
@lobster-online-report
@cp report.lobster report.reference_output
@lobster-html-report
@if diff report.lobster $(REFERENCE_OUTPUT); then \
echo "Files are identical"; \
else \
echo "Files are different"; \
exit 1; \
fi

softreq.lobster: example.rsl softreq_example.trlc sysreq_example.trlc
@lobster-trlc example.rsl softreq_example.trlc sysreq_example.trlc\
Expand Down
27 changes: 12 additions & 15 deletions tests-integration/projects/coverage-half/report.reference_output
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@
{
"tag": "req sysreq_coverage_example.requirement_1a",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-half/sysreq_example.trlc",
"line": 4
"kind": "file",
"file": "sysreq_example.trlc",
"line": 4,
"column": 37
},
"name": "sysreq_coverage_example.requirement_1a",
"messages": [],
Expand All @@ -41,11 +40,10 @@
{
"tag": "req softreq_coverage_example.requirement_2a",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-half/softreq_example.trlc",
"line": 5
"kind": "file",
"file": "softreq_example.trlc",
"line": 5,
"column": 39
},
"name": "softreq_coverage_example.requirement_2a",
"messages": [],
Expand All @@ -65,11 +63,10 @@
{
"tag": "req softreq_coverage_example.requirement_2b",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-half/softreq_example.trlc",
"line": 11
"kind": "file",
"file": "softreq_example.trlc",
"line": 11,
"column": 39
},
"name": "softreq_coverage_example.requirement_2b",
"messages": [
Expand Down
10 changes: 7 additions & 3 deletions tests-integration/projects/coverage-mix/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,16 @@ PYTHONPATH:=$(wildcard $(LOBSTER_ROOT)/test_install/lib/python*/site-packages)

THIS_TEST:=$(shell realpath --relative-to $(LOBSTER_ROOT) $(PWD))
THIS_TEST_ESCAPED:=$(subst /,\\/,$(THIS_TEST))
REFERENCE_OUTPUT:=report.reference_output

html_report.html: softreq.lobster sysreq.lobster testreq.lobster lobster.conf trlc-softreq.conf trlc-sysreq.conf trlc-testreq.conf
@lobster-report
@lobster-online-report
@cp report.lobster report.reference_output
@lobster-html-report
@if diff report.lobster $(REFERENCE_OUTPUT); then \
echo "Files are identical"; \
else \
echo "Files are different"; \
exit 1; \
fi

softreq.lobster: example.rsl softreq_example.trlc sysreq_example.trlc testreq_example.trlc
@lobster-trlc example.rsl softreq_example.trlc sysreq_example.trlc testreq_example.trlc\
Expand Down
27 changes: 12 additions & 15 deletions tests-integration/projects/coverage-mix/report.reference_output
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@
{
"tag": "req softreq_coverage_half_example.requirement_d",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-mix/softreq_example.trlc",
"line": 5
"kind": "file",
"file": "softreq_example.trlc",
"line": 5,
"column": 44
},
"name": "softreq_coverage_half_example.requirement_d",
"messages": [],
Expand All @@ -41,11 +40,10 @@
{
"tag": "req sysreq_coverage_half_example.requirement_e",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-mix/sysreq_example.trlc",
"line": 5
"kind": "file",
"file": "sysreq_example.trlc",
"line": 5,
"column": 42
},
"name": "sysreq_coverage_half_example.requirement_e",
"messages": [
Expand All @@ -70,11 +68,10 @@
{
"tag": "req testreq_coverage_half_example.requirement_f",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-mix/testreq_example.trlc",
"line": 5
"kind": "file",
"file": "testreq_example.trlc",
"line": 5,
"column": 40
},
"name": "testreq_coverage_half_example.requirement_f",
"messages": [],
Expand Down
10 changes: 7 additions & 3 deletions tests-integration/projects/coverage-zero/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,16 @@ PYTHONPATH:=$(wildcard $(LOBSTER_ROOT)/test_install/lib/python*/site-packages)

THIS_TEST:=$(shell realpath --relative-to $(LOBSTER_ROOT) $(PWD))
THIS_TEST_ESCAPED:=$(subst /,\\/,$(THIS_TEST))
REFERENCE_OUTPUT:=report.reference_output

html_report.html: softreq.lobster sysreq.lobster lobster.conf trlc-softreq.conf trlc-sysreq.conf
@lobster-report
@lobster-online-report
@cp report.lobster report.reference_output
@lobster-html-report
@if diff report.lobster $(REFERENCE_OUTPUT); then \
echo "Files are identical"; \
else \
echo "Files are different"; \
exit 1; \
fi

softreq.lobster: example.rsl softreq_example.trlc sysreq_example.trlc
@lobster-trlc example.rsl softreq_example.trlc sysreq_example.trlc\
Expand Down
27 changes: 12 additions & 15 deletions tests-integration/projects/coverage-zero/report.reference_output
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@
{
"tag": "req sysreq_coverage_example.requirement_4a",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-zero/sysreq_example.trlc",
"line": 4
"kind": "file",
"file": "sysreq_example.trlc",
"line": 4,
"column": 37
},
"name": "sysreq_coverage_example.requirement_4a",
"messages": [
Expand All @@ -39,11 +38,10 @@
{
"tag": "req softreq_coverage_example.requirement_3a",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-zero/softreq_example.trlc",
"line": 5
"kind": "file",
"file": "softreq_example.trlc",
"line": 5,
"column": 39
},
"name": "softreq_coverage_example.requirement_3a",
"messages": [
Expand All @@ -61,11 +59,10 @@
{
"tag": "req softreq_coverage_example.requirement_3b",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage-zero/softreq_example.trlc",
"line": 10
"kind": "file",
"file": "softreq_example.trlc",
"line": 10,
"column": 39
},
"name": "softreq_coverage_example.requirement_3b",
"messages": [
Expand Down
10 changes: 7 additions & 3 deletions tests-integration/projects/coverage/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,16 @@ PYTHONPATH:=$(wildcard $(LOBSTER_ROOT)/test_install/lib/python*/site-packages)

THIS_TEST:=$(shell realpath --relative-to $(LOBSTER_ROOT) $(PWD))
THIS_TEST_ESCAPED:=$(subst /,\\/,$(THIS_TEST))
REFERENCE_OUTPUT:=report.reference_output

html_report.html: softreq.lobster sysreq.lobster lobster.conf trlc-softreq.conf trlc-sysreq.conf
@lobster-report
@lobster-online-report
@cp report.lobster report.reference_output
@lobster-html-report
@if diff report.lobster $(REFERENCE_OUTPUT); then \
echo "Files are identical"; \
else \
echo "Files are different"; \
exit 1; \
fi

softreq.lobster: example.rsl softreq_example.trlc sysreq_example.trlc
@lobster-trlc example.rsl softreq_example.trlc sysreq_example.trlc\
Expand Down
18 changes: 8 additions & 10 deletions tests-integration/projects/coverage/report.reference_output
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@
{
"tag": "req sysreq_coverage_example.requirement_1",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage/sysreq_example.trlc",
"line": 4
"kind": "file",
"file": "sysreq_example.trlc",
"line": 4,
"column": 37
},
"name": "sysreq_coverage_example.requirement_1",
"messages": [],
Expand All @@ -41,11 +40,10 @@
{
"tag": "req softreq_coverage_example.requirement_2",
"location": {
"kind": "github",
"gh_root": "https://github.com/bmw-software-engineering/lobster",
"commit": "main",
"file": "tests-integration/projects/coverage/softreq_example.trlc",
"line": 5
"kind": "file",
"file": "softreq_example.trlc",
"line": 5,
"column": 39
},
"name": "softreq_coverage_example.requirement_2",
"messages": [],
Expand Down

0 comments on commit 8dafc12

Please sign in to comment.