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

Add test for withCredentials option #8855

Merged

Conversation

Rob--W
Copy link
Member

@Rob--W Rob--W commented Aug 31, 2017

Add unit test to avoid regressing on #8848.

Locally, I verified that without #8848, some of the new tests fail.
With #8848 (which has been merged), all added tests pass.

@Rob--W Rob--W added the test label Aug 31, 2017
@Rob--W Rob--W requested a review from yurydelendik August 31, 2017 12:13
@Rob--W
Copy link
Member Author

Rob--W commented Aug 31, 2017

/botio unittest

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_unittest from @Rob--W received. Current queue size: 1

Live output at: http://54.215.176.217:8877/1e4ae32518fb22e/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_unittest from @Rob--W received. Current queue size: 1

Live output at: http://54.67.70.0:8877/900ce81c2b17981/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/900ce81c2b17981/output.txt

Total script time: 2.56 mins

  • Unit Tests: Passed

it('server allows cors without credentials, and withCredentials=false',
function(done) {
testCanLoad('basicapi.pdf?cors=withoutCredentials', {
withoutCredentials: false,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Is this supposed to read withCredentials: false, instead, given the test name?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed, thanks. The current default is also withCredentials: false, so the misspelled name doesn't affect the test result.

@Rob--W Rob--W force-pushed the fetch-withCredentials-fix-default branch from 160704f to 73273cc Compare August 31, 2017 12:30
@pdfjsbot
Copy link

From: Bot.io (Windows)


Failed

Full output at http://54.215.176.217:8877/1e4ae32518fb22e/output.txt

Total script time: 0.20 mins

Copy link
Contributor

@yurydelendik yurydelendik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thank you for the patch.

@yurydelendik
Copy link
Contributor

/botio test

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_test from @yurydelendik received. Current queue size: 0

Live output at: http://54.67.70.0:8877/2ae9bc29b05ac6c/output.txt

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_test from @yurydelendik received. Current queue size: 0

Live output at: http://54.215.176.217:8877/b03a5e8f69a9185/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/2ae9bc29b05ac6c/output.txt

Total script time: 16.52 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@pdfjsbot
Copy link

From: Bot.io (Windows)


Failed

Full output at http://54.215.176.217:8877/b03a5e8f69a9185/output.txt

Total script time: 29.34 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: FAILED

Image differences available at: http://54.215.176.217:8877/b03a5e8f69a9185/reftest-analyzer.html#web=eq.log

@Rob--W
Copy link
Member Author

Rob--W commented Aug 31, 2017

This a unittest-only change, so the failure in the non-unit tests are obviously not caused by this PR.

Most of my recent test runs for other patches failed tests on Windows. The noise is a bit distracting, is something being done against that?

@yurydelendik yurydelendik merged commit 47789b5 into mozilla:master Aug 31, 2017
@timvandermeij
Copy link
Contributor

@Rob--W Most of them are fixed, but only the person with dog PDF remains intermittent on Windows. I'd say just ignore that one for now; if it last a long time, we can always decide to temporarily disable it.

Thank you for providing this unit test!

movsb pushed a commit to movsb/pdf.js that referenced this pull request Jul 14, 2018
…-default

Add test for withCredentials option
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants