Skip to content
This repository was archived by the owner on Dec 9, 2024. It is now read-only.

Conversation

@alexdebrie
Copy link
Contributor

What did you implement:

Changed the validation requirement on the Source field of the Event struct to require a URI, rather than a URL. This is according to the CloudEvents spec.

How did you implement it:

Changed validation on Source from validate:"url,required" to validate:"uri,required".

I also changed the test that checks that a valid CloudEvent is not transformed into a CloudEvent. I changed the test case's source to be a URI rather than a URL so that we would catch this in the future.

How can we verify it:

Emit an event in CloudEvents format that uses a URI (not URL) in the source property. Make sure that it wasn't transformed into a CloudEvent.

Todos:

  • Write tests
  • Write documentation
  • Fix linting errors
  • Make sure code coverage hasn't dropped
  • Provide verification commands / resources
  • Enable "Allow edits from maintainers" for this PR
  • Update the messages below

Is this ready for review?: YES
Is it a breaking change?: NO

@alexdebrie alexdebrie requested a review from mthenw April 26, 2018 01:55
@codecov
Copy link

codecov bot commented Apr 26, 2018

Codecov Report

Merging #414 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #414   +/-   ##
=======================================
  Coverage   63.85%   63.85%           
=======================================
  Files          29       29           
  Lines        1649     1649           
=======================================
  Hits         1053     1053           
  Misses        553      553           
  Partials       43       43
Impacted Files Coverage Δ
event/event.go 69.35% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e3b1318...2e7980d. Read the comment docs.

@mthenw mthenw merged commit 529cc4a into master Apr 26, 2018
@mthenw mthenw deleted the CloudEventsSource branch April 26, 2018 07:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants