-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementation of Platform API verification #233
Conversation
Signed-off-by: Javier Romero <[email protected]>
Signed-off-by: Javier Romero <[email protected]>
Signed-off-by: Javier Romero <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel a little iffy about introducing happy path acceptance tests that don't actually do the full setup etc. I think between the unit tests of the compatibility verification and the unhappy path tests we should be covered.
If you feel strongly that we should have them, we need to do more to control the test inputs (images that will never exist, temp dirs or discard for all relevant directories).
@jromero I think |
- Clean up acceptance tests - Make PLATFORM_API configurable - Add verification to rebaser - Consolidate API compatibility method Signed-off-by: Javier Romero <[email protected]>
d18d059
to
2b15a56
Compare
Accepted with: ± zm |master U:1 ✗| → docker run -it -e CNB_PLATFORM_API=0.1 cnb/sample:accept-lifecycle-0.0.6
cnb@7a46687c39a6:/layers$ /lifecycle/detector
ERROR: failed to : the Lifecycle's Platform API version is 0.2 which is incompatible with Platform API version 0.1
cnb@7a46687c39a6:/layers$ exit
|2.6.3| NY-Floater-15565 in ~/workspace/samples
± zm |master U:1 ✗| → docker run -it -e CNB_PLATFORM_API=0.2 cnb/sample:accept-lifecycle-0.0.6
cnb@5d6c4e2002ea:/layers$ /lifecycle/detector
ERROR: No buildpack groups passed detection.
ERROR: Please check that you are running against the correct path.
ERROR: failed to detect: no buildpacks participating
cnb@5d6c4e2002ea:/layers$ exit
|2.6.3| NY-Floater-15565 in ~/workspace/samples
± zm |master U:1 ✗| → docker run -it -e CNB_PLATFORM_API=0.3 cnb/sample:accept-lifecycle-0.0.6
cnb@e252b0b054a7:/layers$ /lifecycle/detector
ERROR: failed to : the Lifecycle's Platform API version is 0.2 which is incompatible with Platform API version 0.3
cnb@e252b0b054a7:/layers$ exit
|2.6.3| NY-Floater-15565 in ~/workspace/samples
± zm |master U:1 ✗| → docker run -it -e CNB_PLATFORM_API= cnb/sample:accept-lifecycle-0.0.6
cnb@90d6bce17f99:/layers$ /lifecycle/detector
ERROR: No buildpack groups passed detection.
ERROR: Please check that you are running against the correct path.
ERROR: failed to detect: no buildpacks participating
cnb@90d6bce17f99:/layers$ exit
|2.6.3| NY-Floater-15565 in ~/workspace/samples
± zm |master U:1 ✗| → docker run -it -e CNB_PLATFORM_API='' cnb/sample:accept-lifecycle-0.0.6
cnb@97c404171261:/layers$ /lifecycle/detector
ERROR: No buildpack groups passed detection.
ERROR: Please check that you are running against the correct path.
ERROR: failed to detect: no buildpacks participating
cnb@97c404171261:/layers$ exit |
Implements verification according to buildpacks/spec#67.
Caveats:
rebaser
in the RFC or spec so I left it out. Should it be included?Notes:
At this time it's not all too relevant given we are pre-stable but would like to document it accurately.
Resolves #224