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

Multiple course material with same "order no" after using patch request #75

Open
BeatBioInfo opened this issue Jul 1, 2022 · 2 comments
Labels
question Further information is requested

Comments

@BeatBioInfo
Copy link

BeatBioInfo commented Jul 1, 2022

Steps to reproduce
Create a collection on Postman
Click on the “add request” button
Use the POST method to call a request http://qa-school-test-api.quantori.academy/api/v1/session
Enter the following “string” in the “Body” in the following order

{
“username”: “admin”,
“password”: “1234”
}

Press the “send” button to generate an “accessToken”.
Click “Add request” to call a 'all materials within a course'.
Use the GET method to call a request {{Host}}api/v1/courses/3093/materials.
Empty body string
Then send the request.

Actual behavior
Status code: 200
Test request:

pm.test("Status code is 200", function () {
    pm.response.to.have.status(200);
});

pm.test("Response time is less than 1000ms", function () {
    pm.expect(pm.response.responseTime).to.be.below(1000);
});

pm.test("Successful POST request", function () {
    pm.expect(pm.response.code).to.be.oneOf([200]);
});

Expected behavior
PASS: Status code is 200
PASS: Response time is less than 1000ms
PASS: GET request
Body: Displayed all created course materials specific to a course (3093)

** Course should be displayed in order regardless of when they are created.

Screenshots
If applicable, add screenshots to help explain your problem.
image
image

@viraxslot
Copy link
Owner

@BeatBioInfo sorry, I don't understand this bug. Could you please provide more information? What's wrong with actual behavior?

@viraxslot viraxslot added the question Further information is requested label Jul 15, 2022
@BeatBioInfo
Copy link
Author

@viraxslot Thanks for your feedback. I would expect that each course material has a specified order number within a course. Using the above image as an illustration, "id: 163 and id: 166" should be in sequential order after updating the course material i.e., "order": 1 and "order": 2 respectively. I think it should be impossible to assign the same order no to different course materials unless the order is insignificant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants