Skip to content

deissnerk/conformance

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CloudEvents Conformance Testing

cloudevents is a tool for testing CloudEvents receivers.

GoDoc Go Report Card

Work in progress.

Installation

cloudevents can be installed via:

go get github.com/cloudevents/conformance/cmd/cloudevents

To update your installation:

go get -u github.com/cloudevents/conformance/cmd/cloudevents

Usage

cloudevents has three commands at the moment: send, invoke and listen.

Send

send will do a one-off creation of a cloudevent and send to a given target.

cloudevents send http://localhost:8080 --id abc-123 --source cloudevents.conformance.tool --type foo.bar

Invoke

invoke will read yaml files, convert them to http and send them to the given target.

cloudevents invoke http://localhost:8080 -f ./yaml/v0.3

Listen

listen will accept http request and write the converted yaml to stdout.

cloudevents listen -v > got.yaml

Optionally, you can forward the incoming request to a target.

cloudevents listen -v -t http://localhost:8181 > got.yaml

Advanced Usage

If you would like to produce a pre-produced event yaml file, you can use listen to collect requests. This works with both running event producers that can be directed at the listen port or directly with send.

TODO

Feature requests:

  • Add a yaml command that allows the same format of send but direct to yaml.
  • Add a --yaml flag to send that outputs what the definition of the sent event would look like in yaml.
  • Add -f - support for reading from STDIN as the file for yaml, this allows for send | invoke chaining.
  • Add format support to send to select binary or structured.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 82.3%
  • Gherkin 14.5%
  • Shell 3.2%