Commit Graph

1365 Commits

Author SHA1 Message Date
Christian Klaussner
0e9660097d Update self-tests for mongo-free autoupdate 2018-11-03 13:32:01 -04:00
Ben Newman
c96278700d Fix compiler plugins self-tests by waiting for lazy compilation to finish. 2018-10-31 10:41:31 -04:00
Ben Newman
18762f97a2 Update modules test app to Meteor 1.8. 2018-10-13 19:32:10 -04:00
Ben Newman
94771d233e Update dynamic-import test app to Meteor 1.8. 2018-10-13 19:27:48 -04:00
Ben Newman
c5f6c270b7 Avoid modifying source files explicitly added by compiler plugins.
Should resolve #10233, reported by @klaussner.

Previously, if a compiler plugin called inputFile.addJavaScript multiple
times with different { path } strings, Meteor would allow importing all of
those modules at once by importing the original source module identifier,
by synthesizing a new source module containing a series of re-exports for
each of the generated modules.

Preserving this behavior is important for backwards compatibility, since
some compiler plugins still generate files like "module.ext.js" given an
input file named "module.ext", so Meteor tries to make those modules
interchangeable/synonymous.

However, if the compiler plugin explicitly calls inputFile.addJavaScript
with the original source path, then it would be a mistake to modify the
contents of that module, so Meteor will now leave the contents of that
explicit source module unmodified, rather than using it as a catch-all way
to import other generated modules.
2018-10-03 15:13:08 -04:00
Ben Newman
ac5410e75a Merge branch 'devel' into release-1.7.1 2018-09-12 12:38:37 -04:00
mrauhu
5574f22df5 Fix: file Meteor_:-@2x.png breaks development on Windows (#10110)
* Rename file that breaks development on Windows

* Fix: failing test bundle - verify sanitized asset names
2018-09-12 18:55:38 +03:00
Ben Newman
1a472a4161 Simplify external symlink handling in Builder#copyDirectory.
Follow-up to af51b816, which fixed #8005 by copying symlinks to external
directories as directories rather than trying to preserve the symlinks.

Issue #10177 revealed a flaw in this strategy: the filter function that we
use to strip development npm packages always rejects external paths, even
if the original symlink was found in a valid production npm package, and
thus its contents should be included in the production bundle.

In the process of fixing this problem, I realized that the only important
part of af51b816 was this code:

  // Update fileStatus to match the actual file rather than the
  // symbolic link, thus forcing the file to be copied below.
  fileStatus = optimisticLStatOrNull(externalPath);

and the code for manipulating thisAbsFrom and _currentRealRootDirectory
could be removed.
2018-09-05 21:30:27 -04:00
Ben Newman
9d75b0976e Merge branch 'master' into devel 2018-08-16 18:02:22 -04:00
Ben Newman
09194e86e8 Merge branch 'dynamic-import-0.4.2' into release-1.7.0.5 2018-08-16 13:20:05 -04:00
Ben Newman
8eb081336b Ignore bad POST requests in dynamic-import request handler.
Should help mitigate #10147.
2018-08-16 13:14:23 -04:00
Ben Newman
1cc5661f15 Ignore bad POST requests in dynamic-import request handler.
Should help mitigate #10147.
2018-08-16 10:10:00 -04:00
Ben Newman
9872a3a71d Tests for @x.y.z! package version constraint override syntax.
Following up on this promise:
https://github.com/meteor/meteor/pull/9942#commitcomment-30080110
2018-08-15 14:05:12 -04:00
Christian Klaussner
340c7d9ab5 Update mongo test to match MongoDB 4.0 output (#10058)
The `mongo` shell is run with the `--quiet` option (7f7a987251), so there's no more output to match.
2018-08-09 16:09:35 -04:00
Ben Newman
29ce8f2142 Adjust @babel/runtime version constraints in test app package.json files.
According to the plan described in #10134, whereas we had to pin these
versions to exactly 7.0.0-beta.55 for Meteor 1.7.0.4, we must now require
at least 7.0.0-beta.56 for Meteor 1.7.1, since other @babel/... packages
used by babel-compiler and meteor-babel are currently at beta.56.
2018-08-07 13:49:32 -04:00
Ben Newman
defbf6d6eb Merge branch 'devel' into release-1.7.1 2018-08-07 13:30:16 -04:00
Ben Newman
aba03743ad Update dynamic-import test app to Meteor 1.7.0.4.
Unit tests will still run the app from a checkout of the devel branch, but
it's worth noting that Meteor 1.7.0.4 also works for this app.
2018-08-07 12:33:15 -04:00
Ben Newman
228688cb8c Update vulnerable moment dependency of modules test app. 2018-08-07 12:28:44 -04:00
Ben Newman
619a8b6924 Merge branch 'master' into devel 2018-08-07 11:49:34 -04:00
Ben Newman
ec6716ce7e Pin another @babel/runtime dependency in an old test app. 2018-08-06 18:42:13 -04:00
Ben Newman
7593c74a7b Pin test app @babel/... dependencies to version 7.0.0-beta.55.
Also updated the dynamic-import test app to Meteor 1.7.0.3.
2018-08-06 12:35:23 -04:00
Ben Newman
2603f7c06a Add akryum:vue-component to modules test app to verify #10129 fix. 2018-08-06 11:15:29 -04:00
Ben Newman
818022dd02 Update moment dependency of modules test app to appease npm audit. 2018-08-06 11:15:28 -04:00
Ben Newman
d2942614ae Update modules test app to Meteor 1.7.1-beta.28. 2018-08-06 11:10:34 -04:00
Ben Newman
bcaeed676e Move puppeteer back to dependencies for test applications.
This should fix test failures, because apparently it's important that
puppeteer not be installed in devDependencies.
2018-08-04 14:49:55 -04:00
Ben Newman
b23b1213f4 Update @babel/... dependencies of modules test app to 7.0.0-beta.56.
Also moving puppeteer to devDependencies.
2018-08-04 14:27:38 -04:00
Ben Newman
ce68c4b91c Update dynamic-import test app dependencies. 2018-08-04 14:12:23 -04:00
Ben Newman
7dc77cdaf1 Fix importing local .json modules within Meteor packages.
The ImportScanner was mistakenly generating module.useNode() stub modules
for local .json files within Meteor packages, just because their absolute
module identifiers include "node_modules", which happens because we put
package modules under the /node_modules/meteor/<package name/ namespace.

Fix: make logic for determining when to generate module.useNode() stubs
match Module.prototype.useNode logic in modules-runtime/server.js.

Closes #10122.
2018-08-03 11:07:51 -04:00
Ben Newman
a4657f34d5 Merge branch 'devel' into release-1.7.1 2018-07-19 17:53:10 -04:00
Ben Newman
35473f29e4 Move package.json private field stripping tests into modules test app.
Follow-up to #9903.
2018-07-19 15:31:17 -04:00
Bartosz Wojtkowiak
c6b136d3ca Remove non deterministic fields from included package.json files. (#9903) 2018-07-19 12:30:17 -07:00
Ben Newman
2cc172bbed Fix meteor scripts in tools/tests/apps/modules/package.json. 2018-07-18 12:48:35 -04:00
Ben Newman
a756af487b Merge branch 'devel' into release-1.7.1 2018-07-18 12:42:01 -04:00
Ben Newman
2450ffe84d Remove unreliable modification of Autoupdate versions from self-test. 2018-07-16 18:59:51 -04:00
Toine van Kampen
92b72bc46b Fix Failing Tests
Ensure Hot Code Push and Package Tests account for possible multiple runs.
2018-07-15 10:17:01 +10:00
Jesse Rosenberger
f7752a071a Merge branch 'devel' into HEAD 2018-07-11 09:29:26 -07:00
Ben Newman
8b04c25390 Emit multiple meteorInstall calls for distinct meteorInstallOptions.
I recently noticed a bug whereby modules transferred from the application
bundle to the modules bundle would lose their application-specific import
extensions, since all modules installed in the modules bundle have only
.js and .json as import extensions, matching default Node behavior.

This commit fixes that bug by emitting one meteorInstall call per distinct
meteorInstallOptions object. This logic would work if every module had a
different meteorInstallOptions object, but in practice the modules bundle
should end up with exactly two meteorInstall calls, because a single
options object is shared among all modules from the same source batch.
2018-06-28 18:07:34 -04:00
Ben Newman
9f7ef9cdb1 Fix compiler plugins caching self-test for the stylus plugin. 2018-06-26 13:09:37 -04:00
Ben Newman
f7f3d34181 Mark non-isRoot files lazy in MultiFileCachingCompiler.
The concept of a "root" file is specific to MultiFileCachingCompiler, so
we need to normalize it into a representation that makes sense to the rest
of the compiler plugin system.

Should help with #10014.
2018-06-26 13:09:14 -04:00
Ben Newman
35e6d912e0 Fix compiler plugins caching self-test for the stylus plugin. 2018-06-23 09:57:38 -04:00
Ben Newman
fb8bcf44b0 Mark non-isRoot files lazy in MultiFileCachingCompiler.
The concept of a "root" file is specific to MultiFileCachingCompiler, so
we need to normalize it into a representation that makes sense to the rest
of the compiler plugin system.

Should help with #10014.
2018-06-22 16:43:54 -04:00
Jesse Rosenberger
07f3290da1 Merge branch 'devel' into devel 2018-06-14 14:40:20 +03:00
Ben Newman
f0e04facd2 Update dynamic-import test app to Meteor 1.7.0.1. 2018-06-07 11:36:34 -04:00
Toine van Kampen
499bb7ea25 Merge remote-tracking branch 'meteor/devel' into devel
Rebaseline
2018-06-06 20:28:03 +10:00
Ben Newman
0fcf29eaee Update modules test app to Meteor 1.7. 2018-05-27 20:38:01 -04:00
Ben Newman
dbdadc1b11 Avoid using "browser" field of package.json for inputFile.resolve.
Fixes #9870.
2018-05-12 12:43:54 -04:00
Ben Newman
b7579ad100 Update modules test app to Meteor 1.7-rc.5. 2018-05-09 19:12:13 -04:00
Ben Newman
81248867aa Update meteor-node-stubs to version 0.4.1.
This only affects newly created applications for now, but developers can
update to the latest meteor-node-stubs by running

  meteor npm install meteor-node-stubs@latest

https://github.com/meteor/node-stubs/issues/15
2018-05-08 12:56:03 -04:00
Ben Newman
7baaf19020 Report an error when meteor.mainModule cannot be resolved.
https://github.com/meteor/meteor/pull/9826#issuecomment-387172568
2018-05-07 18:48:38 -04:00
Toine van Kampen
f666568e40 Merge remote-tracking branch 'meteor/devel' into devel
Rebaseline
2018-05-01 06:31:00 +10:00