Граф коммитов

808 коммитов

Автор SHA1 Сообщение Дата
renovate[bot]
9b699ff9a8
fix(deps): update module github.com/cucumber/godog to v0.15.0 (#661)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-11-02 01:42:01 +00:00
Viacheslav Poturaev
dc6950b1e3 Update CHANGELOG.md 2024-10-31 19:06:21 +01:00
John Lonergan
ecd2dfebbd
Ambiguous step detection - add support to all formatters (#648)
* added the missing impl of json/events/junit/pretty - still need 'progress' and 'junit,pretty'

* added tests for "progress formatter"

* switched from tabs to spaces in the ambiguous steps error message

* rename some_scenarions_including_failing
to     some_scenarios_including_failing

* changelog
2024-10-16 15:41:47 +01:00
John Lonergan
223efc3b14
Fix some type checks on the signatures of nested step handlers (#647)
* at some point someone changed the return type for nested steps from []string to godog.Steps but they forgot to adjust the type checks. The existing type checks were lax and unable to distinguish  []string from godog.Steps but in a couple of places in the code the value is coerced to godog.Steps and so if someone returned []string then the code would blow up. Additionally there were some tests aroudn these types but they also had not been updated but the test was passing for the wrong reason - the particular test expected an error but the cause of the error wasn't the one the code expected.

* CHANGELOG.md

* use chatgpt to regen the top of the code based on the new tests

* use chatgpt to regen the top of the code based on the new tests

* corrected the error messages of the param checks to indicate that the problem is the function signature and not the args being passed to the function, also added numerous extra assertions on the precise error messages returned. Now that the precise error is being verified in the test I have improved certain error messages to that more accurate detail is included in the errors

* added further constraints to the step arg mapping tests

* removed redundant test

* include a step error result in the reported error even when the ctx is nil
2024-10-15 13:25:13 +01:00
John Lonergan
8edde7f30c
Bugfix afterscenario attachments (#646)
* Minor doc and comment corrections

* Fixed bug where it was impossible to make attachments from 'after scenario' hook, also removed some dud comments.

* typo
2024-10-06 02:12:56 +01:00
John Lonergan
1e7c45eb78
Minor doc and comment corrections (#644) 2024-10-05 02:40:42 +01:00
M.P. Korstanje
6e4f452389
Replace more slack with discord
See:
- https://github.com/cucumber/common/issues/2195
- https://github.com/orgs/cucumber/discussions/2197
2024-08-09 16:58:01 +02:00
M.P. Korstanje
9b51734429
Replace slack with discord
See:
- https://github.com/cucumber/common/issues/2195
- https://github.com/orgs/cucumber/discussions/2197
2024-08-09 16:51:01 +02:00
John Lonergan
901da7fa3d
fixed a bug where the attachments are extracted from the context too early, this prevented AfterStep from making attachments (#637)
* fixed a bug where the attachments are extracted from the context too early, this prevented AfterStep from making attachments
2024-07-23 17:22:51 +01:00
John Lonergan
bcf6bce793
ambiguous step def detection akin to cucumber jvm (#636)
* added basic detection for ambiguous steps, but causes an error and not yet recorded in the reports as 'Ambiguous', and no test cases figured out yet

* added initial support for detection of ambiguous steps - further work take a look at how cuke jvm report ambiguous steps and sets the step status to 'ambiguous' rather than my current solution which just blows the test up as a regular step error

* added suite_context_test and also introduced missing 'ambiguous' status to make cucumber jvm'

* update CHANGELOG for ambiguous step defs

* missed file from commit

* added internal/formatters/fmt_multi_test.go

* add tests for other peoples code

* added "ambigous" to the help text

* tests

* added some more tests for attachments

* Update internal/flags/flags.go

Co-authored-by: Viacheslav Poturaev <nanopeni@gmail.com>

---------

Co-authored-by: Viacheslav Poturaev <nanopeni@gmail.com>
2024-07-01 10:28:39 +01:00
John Lonergan
3abb346b28
provisional: Attachments now uses base64 padding not raw mode (#629)
* corrected base64 encoding of attachments to use padding as that's what cuke JVM does
2024-05-31 21:33:57 +01:00
John Lonergan
9558224cce
Additional code review observations on Attach() functionality from https://github.com/cucumber/godog/pull/623 (#628)
* support multiple calls to the Attach() function from a single step

* run_progress_test.go changed so it's not sensitive to the name of the clone target directory

* applied code review comments also added _example/attachments

* applied code review comments also added _example/attachments

* applied code review comments also added _example/attachments
2024-05-30 02:29:14 +00:00
John Lonergan
f85def32ee
Moved CHANGHELOG entry to correct location (#626) 2024-05-29 09:19:33 +02:00
John Lonergan
201e526078
added support for Attachments (aka Embedddings) (#623)
* added support for attachments in the cucumber json and events output formats - done by sneaking the attachment into the context.Context object.
2024-05-29 00:02:08 +01:00
Viacheslav Poturaev
4ade3314e8
Update CI and Makefile (#619) 2024-05-02 14:51:52 +02:00
renovate[bot]
c3756d1aa2
fix(deps): update module github.com/cucumber/godog to v0.14.1 (#618)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-30 14:31:36 +00:00
Viacheslav Poturaev
095a19b85d
Update CHANGELOG.md 2024-04-29 10:49:40 +02:00
Mark Hughes
7017c73ef8
Provide a useful implementation of something compatible with testing.T (#571)
* Attempting to provide a useful implementation of something compatible with testing.T

* Handle Fail calls on the TestingT in the right place

* Provide as much of testing.T as possible + tidy up

* Add initial tests for testingT support

* Check compatibility with testing.T and friends

Co-authored-by: Piotr Bocheński <bochenski.piotr@gmail.com>

* Update assert-godogs example to show new usage. Rename 'GetTestingT(ctx)' to 'T(ctx)'

* Update changelog and readme with new usage

* Improve test coverage

* Review updates

---------

Co-authored-by: Piotr Bocheński <bochenski.piotr@gmail.com>
2024-04-29 10:26:25 +02:00
Cornel Damian
10407bc5a9
fix invalid memory address or nil pointer dereference when calling TestSuite RetrieveFeatures (#566)
Co-authored-by: Cornel Damian <cornel.damian@adswizz.com>
2024-04-08 14:53:28 +02:00
renovate[bot]
fd3e0d5f9c
chore(deps): update actions/cache action to v4 (#598)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-08 14:48:46 +02:00
renovate[bot]
18088dfc91
chore(deps): update codecov/codecov-action action to v4 (#607)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-08 14:48:09 +02:00
Iaroslav Ciupin
da57dd0766
Fix step duration calculation (#616) 2024-04-08 14:08:21 +02:00
renovate[bot]
153db4eacb
chore(deps): update dominikh/staticcheck-action action to v1.3.1 (#614)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-24 21:40:17 +00:00
Glib Briia
27ad3c245e
Create releasing guidelines (#608) 2024-02-06 14:19:51 +00:00
renovate[bot]
244de8274a
fix(deps): update module github.com/cucumber/godog to v0.14.0 (#610)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-01 22:35:22 +00:00
Glib Briia
757988328b
Prepare CHANGELOG.md for new release (#606) 2024-01-31 16:39:28 +00:00
Glib Briia
250d69ab63
Fixes #604 - remove line overwriting for scenario outlines in cucumber formatter (#605) 2024-01-31 07:04:29 +00:00
Viacheslav Poturaev
5a5631a758
Remove duplicate warning message (#590) 2023-12-07 21:34:04 +01:00
renovate[bot]
592f1cdb71
chore(deps): update actions/setup-go action to v5 (#588)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-07 21:29:50 +01:00
Viacheslav Poturaev
888fe3f294
Improve ErrSkip handling, add test for Summary and operations order (#584) 2023-10-29 22:59:14 +01:00
Kirubel Adamu
25274b0291
updated base formatter to set a scenario as passed unless there exist… (#582) 2023-10-27 19:28:41 +02:00
Viacheslav Poturaev
c61a93931d
Update test.yml (#583) 2023-10-24 00:11:29 +02:00
renovate[bot]
76039dc0d2
chore(deps): update codecov/codecov-action action to v4 (#576)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-09-14 19:05:33 +02:00
renovate[bot]
4550862450
chore(deps): update actions/checkout action to v4 (#575)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-09-07 18:56:06 +02:00
renovate[bot]
a37ff90667
fix(deps): update module github.com/cucumber/godog to v0.13.0 (#574)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-08-23 20:45:17 +00:00
Viacheslav Poturaev
6b96d47e70 Prepare CHANGELOG.md for new release 2023-08-22 14:31:19 +02:00
Viacheslav Poturaev
d3aec7142e
Improve example with concurrency support (#573) 2023-08-22 14:21:34 +02:00
Yury Yurochko
75d5cab90d
fix(examples): update api example (#532) 2023-08-17 11:23:10 +02:00
Viacheslav Poturaev
3e0f9026f3
Improve hooks invocation flow (#568) 2023-07-13 09:31:56 +02:00
Viacheslav Poturaev
51d164ff57 Print verbose error to enable traces 2023-07-07 18:16:21 +02:00
Longyue Li
72db47c519
refactor: test_context.go (#564)
* 1. ScenarioContext has methods on both value and pointer receivers, make all methods have value receivers.
2. fix the syntax error in the comment
3. remove unused function Build

Signed-off-by: longyue0521 <longyueli0521@gmail.com>

* convert ctx (type ScenarioContext) to StepContext

Signed-off-by: longyue0521 <longyueli0521@gmail.com>

* rollback the deleted Build function

Signed-off-by: longyue0521 <longyueli0521@gmail.com>

---------

Signed-off-by: longyue0521 <longyueli0521@gmail.com>
2023-06-07 11:37:46 +02:00
Viacheslav Poturaev
ea50e4bdfc
Use staticcheck GitHub Action (#563) 2023-06-06 16:52:06 +02:00
Viacheslav Poturaev
7f75c5d4ee Remove redundant return 2023-05-26 16:43:48 +02:00
Viacheslav Poturaev
35820ff9fe Reduce deps, fix CI for go1.16, format imports 2023-05-26 16:38:51 +02:00
Viacheslav Poturaev
3eae6c0437 Update dependencies 2023-05-26 14:57:29 +02:00
Viacheslav Poturaev
561cb85371 Add test for context cancellation 2023-04-04 01:30:19 +02:00
Dragan Milic
0dcbfef9be
cancel context for each scenario (#514)
* fix(deps): update module github.com/cucumber/gherkin/go/v26 to v26.1.0 (#549)

* Update CI for go1.20 (#552)

* fix(deps): update module github.com/cucumber/gherkin/go/v26 to v26.1.0

* Tidy modules

---------

Co-authored-by: Viacheslav Poturaev <vearutop@gmail.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* cancel context for each scenario

* Update suite.go

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Viacheslav Poturaev <vearutop@gmail.com>
Co-authored-by: Viacheslav Poturaev <nanopeni@gmail.com>
2023-04-04 01:28:03 +02:00
renovate[bot]
472ea2735d
fix(deps): update module github.com/cucumber/gherkin/go/v26 to v26.1.0 (#549)
* Update CI for go1.20 (#552)

* fix(deps): update module github.com/cucumber/gherkin/go/v26 to v26.1.0

* Tidy modules

---------

Co-authored-by: Viacheslav Poturaev <vearutop@gmail.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-04-04 00:43:31 +02:00
Viacheslav Poturaev
aba6a689a4
Update CI for go1.20 (#552) 2023-04-04 00:11:09 +02:00
Tomohiko Himura
dc8c9c4378
Result of testing.T respect strict option (#539)
* test: testing.T.Failed should be false when strict is false and has pending steps

* fix: testing.T respect strict option
2023-04-03 16:05:05 +02:00