Skip to content

Commit

Permalink
Publish option (cucumber#1424)
Browse files Browse the repository at this point in the history
* Added scenario for --publish option

* Add --publish option

* Make publish scenario pass with cheating

* Add a ReportServer to the World

* Start TDDing HttpStream

* Write HttpStream in a temporary file

* Pipe tempfile to http request

* Wait for request to finish before closing server

* Capture body on server

* Wait for the server to receive all the body

* Add new test for GET/PUT redirect between lambda and S3

* Follow Location after get

* Fix dependency lint

* Cleanup

* Refactor

* Extract HttpStream

* Extract FakeReportServer

* Use FakeReportServer in publish.feature

* Add failing spec for --publish

* Scenario is passing

* Print response body in errors. Send content-length

* Added tests for outputting a banner from the report server content

* http_stream logs response from server to console

* Enable publishing report with ENV var

* Fix lint error

* Start adding support for CUCUMBER_PUBLISH_TOKEN

* Publish with Authorization header when CUCUMBER_PUBLISH_TOKEN is set

* Restore newline

* Add scenarios describing the banner advertising --publish

* Start implementing banner display when --publish is not set

* Add isPublishing attribute to configuration

* Add test checking is suppressPublicationBanner is set + added --publish-quiet option

* Print banners to stderr, fixed import of cucumber

* Adapt banner to cucumber.js

* Add ANSI colours to banner

* Extract banner code to its own file

* more maintainable publish banner

* revert dep lint config, lint fix banner

* Use arrow function

* Use doesHaveValue in conditionals. Update comment about 3xx redirects

* Use valueOrDefault instead of boolean expression

* Update changelog

Co-authored-by: Seb Rose <[email protected]>
Co-authored-by: Christophe Bliard <[email protected]>
Co-authored-by: Vincent Pretre <[email protected]>
Co-authored-by: Charles Rudolph <[email protected]>
  • Loading branch information
5 people authored and Adam Karrasch committed Oct 21, 2020
1 parent 6cacb13 commit 963e5f4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/support_code_library_builder/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export interface ITestStepHookParameter {
testCaseStartedId: string
}

export type TestCaseHookFunctionWithoutParameter = () => void
export type TestCaseHookFunctionWithoutParameter = () => void | Promise<void>
export type TestCaseHookFunctionWithParameter = (
arg: ITestCaseHookParameter
) => void | Promise<void>
Expand Down
8 changes: 8 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -655,6 +655,14 @@
"@types/express-serve-static-core" "*"
"@types/mime" "*"

"@types/serve-static@*":
version "1.13.5"
resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.13.5.tgz#3d25d941a18415d3ab092def846e135a08bbcf53"
integrity sha512-6M64P58N+OXjU432WoLLBQxbA0LRGBCRm7aAGQJ+SMC1IMl0dgRVi9EFfoDcS2a7Xogygk/eGN94CfwU9UF7UQ==
dependencies:
"@types/express-serve-static-core" "*"
"@types/mime" "*"

"@types/[email protected]":
version "3.2.4"
resolved "https://registry.yarnpkg.com/@types/sinon-chai/-/sinon-chai-3.2.4.tgz#c425625681f4f8d3a43a7551a77f590ce1c49b21"
Expand Down

0 comments on commit 963e5f4

Please sign in to comment.