Skip to content

Commit 180eb72

Browse files
committed
Add --summary option to gherkinize
This will produce a CSV-format summary of sections, scenarios, and tags. This provides an overview of tags applied, showing the tests which are (currently). This includes extensive testing to get Gherkinize test coverage to 100% This doesn't use red "X" and green Check because those would be limited to the `@wip` tag only.
1 parent d9c3d85 commit 180eb72

7 files changed

Lines changed: 683 additions & 100 deletions

File tree

features/README.rst

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ This can be done using **make** at the top level of the project.
2222

2323
make test
2424

25-
To test work-in-progress (WIP)::
25+
To test work-in-progress (WIP)
26+
27+
::
2628

2729
make test-wip
2830

@@ -61,25 +63,31 @@ Here's the bigger picture workflow:
6163

6264
(Or, create it anywhere and set ``CEL_SPEC_PATH`` to refer to this directory.)
6365

64-
2. Run the ``tools/refresh_spec.``py to find the most recent tag and pull the current files.
66+
2. Run the ``tools/refresh_spec.py`` to find the most recent tag and pull the current files.
6567

66-
5. Run ``make`` to copy the ``.textproto`` files to this directory and create ``.feature`` files from them.
68+
3. Run ``make`` to copy the ``.textproto`` files to this directory and create ``.feature`` files from them.
6769
This will **also** create a ``git.log`` file with the last 5 log entries to help pinpoint
6870
the commit on which the acceptance test suite is based.
6971

70-
Remove the ``.textproto`` and ``.feature`` files and rebuild them:
72+
In rare cases, it can help to remove the ``.textproto`` and ``.feature`` files and rebuild them:
7173

7274
::
7375

7476
make clean all
7577

7678
Changing the ``@wip`` tags in the feature files.
7779

78-
The ``@wip`` tags are added by ``gherkinize.py`` based on a ``wip.toml`` configuration file.
80+
The @wip tags
81+
=============
82+
83+
The ``@wip`` tags are added by ``gherkinize.py`` based on the ``wip.toml`` configuration file.
7984
As features are added, update the ``wip.toml`` file and rebuild the ``.feature`` files, without touching the ``.textproto`` files.
8085

8186
::
8287

8388
make clean-features all
8489

85-
This will reset the tags in the ``.feature`` files.
90+
This will reset the tags in the ``.feature`` files to reflect the current mix
91+
of supported features.
92+
93+
The goal is to eliminate all test cases from the ``wip.toml`` configuration file.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ commands = [
116116

117117
[tool.tox.env.tools]
118118
description = "conformance suite conversion tools"
119-
commands = [["pytest", "-v", "tools"]]
119+
commands = [["pytest", "-vv", "tools", "--cov=tools", "--cov-report=term-missing"]]
120120

121121
[tool.tox.env.wip]
122122
description = "work-in-progress test suite"

tests/test_evaluation.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ def test_operator_in():
191191
assert operator_in(eval_error, container_1) == eval_error
192192
assert operator_in(celtypes.IntType(42), eval_error) == eval_error
193193

194+
194195
@pytest.mark.skipif(
195196
"re2" not in celpy.evaluation.function_matches.__globals__, reason="Not using RE2"
196197
)

0 commit comments

Comments
 (0)