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

__non_webpack_require__ -> require in SystemJS #8781

Merged

Conversation

Rob--W
Copy link
Member

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

When running browser tests, e.g. via gulp unittest, the test files are not processed by babel, and neither by the "unittestcli" gulp target.

This commit copies the babelPluginReplaceNonWebPackRequire plugin from the unittestcli target to the SystemJS config so that __non_webpack_require__ is replaced with require for all build targets, and adds a unit test to ensure that this indeed works as expected.

When running browser tests, e.g. via `gulp unittest`, the test files are not
processed by babel, and neither by the "unittestcli" gulp target.

This commit copies the babelPluginReplaceNonWebPackRequire plugin from the
unittestcli target to the SystemJS config so that `__non_webpack_require__` is
replaced with `require` for all build targets, and adds a unit test to ensure
that this indeed works as expected.
@timvandermeij
Copy link
Contributor

/botio unittest

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_unittest from @timvandermeij received. Current queue size: 0

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

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_unittest from @timvandermeij received. Current queue size: 0

Live output at: http://54.67.70.0:8877/069a8aed9591fa8/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/069a8aed9591fa8/output.txt

Total script time: 2.58 mins

  • Unit Tests: Passed

@pdfjsbot
Copy link

From: Bot.io (Windows)


Success

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

Total script time: 12.88 mins

  • Unit Tests: Passed

@timvandermeij timvandermeij merged commit 81172b5 into mozilla:master Aug 21, 2017
@timvandermeij
Copy link
Contributor

Looks good. Thank you for the patch!

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

__non_webpack_require__ -> require in SystemJS
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.

3 participants