Skip to content
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

Incorrect resource results in 400 error? #678

Closed
bs1180 opened this issue Apr 2, 2015 · 2 comments
Closed

Incorrect resource results in 400 error? #678

bs1180 opened this issue Apr 2, 2015 · 2 comments

Comments

@bs1180
Copy link

bs1180 commented Apr 2, 2015

I'm not sure if this is a test issue or if the spec itself needs clarifying.

I'm testing a simple LRS implementation and found a conformance test that expects a HTTP 400 error for a non-existent endpoint. I suppose this reflects the requirement under section 7:

The LRS MUST reject with HTTP 400 Bad Request status any request to any of these APIs that use any parameters which the LRS does not recognize in their intended context in this specification

My initial reaction was that a 404 might be more appropriate, but on further reflection I think the test itself might be overreaching. The test is looking for something outside "these" APIs by checking for a different resource ("/abouts") which is not part of the xAPI spec. I don't think the spec - or the tests - should be concerned with other resources alongside the base endpoint, but perhaps this is something I've overlooked. Is the base endpoint forbidden from having other endpoints outside those listed in Appendix F?

For example, if my base endpoint is just example.com:
example.com/statements - xAPI endpoint so should be tested
example.com/about - xAPI endpoint so should be tested
example.com/foo - outside the spec so shouldn't be tested

Grateful for some clarification!

@brianjmiller
Copy link
Contributor

@bs1180
Copy link
Author

bs1180 commented Apr 9, 2015

Thanks very much Brian, I'll add a comment to the specific issue and close this.

@bs1180 bs1180 closed this as completed Apr 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants