Commit Graph

32 Commits

Author SHA1 Message Date
Matheus Castro
15b5a397dd Remove Fibers from meteor-tools:
- Bulk changes to self-tests definitions. Now we go into each one to see what's failing and what's not.
2023-01-18 09:50:54 -03:00
Jan Dvorak
b6e127cfc9 Minor tools update
Replace underscore where easy and feasible & other minor modernization that I came across.
2021-06-25 00:36:03 +02:00
seke
a87e9116e6 Fix old-style tests 2019-11-26 15:31:13 -05:00
Ben Newman
8958cbc5e9 Convert tools/fs/watch.js to TypeScript. 2019-07-05 17:50:20 -04:00
Ben Newman
5ed64fb1db Remove explicit .js extension from tools/fs/files imports. 2019-07-04 10:32:09 -04:00
Hugh Willson
540dc00230 Add a self-test skip option (#9579)
* Add a self-test skip option

Meteor's CI infrastructure is configured to exclude certain
`self-test`'s on each run. These excludes are specified in
each CI environment's config file, and included when running
`meteor self-test`. Developers running `meteor self-test`
locally however are not using these excludes by default,
so developer's have to manually look up the current exclude
list from one of the CI configs, then add these excludes to
their own `meteor self-test` call manually.

This commit adds a new `skip` option to Meteor's `self-test`
system, that can be used to skip adding/running a defined
`self-test` (similar in concept to Mocha's `skip` feature).
This provides a way to skip the running of older
`self-test`'s that are no longer needed, but allows them to
be preserved in the `self-test` suite, for future reference.
With this functionality in place, and the older test suites
updated to use it, Meteor's base CI excludes no longer need
to be maintained in their respective config files. The
excludes are all managed at the source (the test definition),
and can be leveraged by anyone/anything calling
`meteor self-test`.

* Log message describing skipped test

* Add manually-ignored count to self-test summary

* Small comment correction

* History.md entry with PR link
2018-01-29 14:25:09 +02:00
Ben Newman
35da19ab4e Avoid "The handle(...) returned by watching..." errors on Linux.
It's a shame that Pathwatcher issues this warning using console.error,
without taking any verbosity options into account:
https://github.com/atom/node-pathwatcher/blob/7ef76e5dfd/src/main.coffee#L53

Fortunately, I believe I've identified the underlying reason why this
happens, which may help resolve the following issue:
https://github.com/atom/node-pathwatcher/issues/98

If all goes well, I'll submit an upstream pull request.

I've also reinstated an old file watching test that I mistakenly removed
when I attempted to switch to chokidar instead of pathwatcher.
2016-10-21 21:14:44 -04:00
Ben Newman
117b1a8525 Use chokidar for file watching instead of pathwatcher.
Healthy competition among fs.watch wrappers appears to have produced a
clear winner: https://www.npmjs.com/package/chokidar

This wrapper is better for Meteor than pathwatcher was, because it can
watch directory trees recursively, and it has no trouble watching
nonexistent file paths, whereas pathwatcher would throw an exception.
2016-10-10 14:12:51 -04:00
Ben Newman
ed17924940 Add braces to every if/for(-in)/while statement in tools directory. 2015-11-13 12:25:19 -05:00
Slava Kim
39d8aef3d9 move files into console/ tool-testing/ 2015-08-06 16:39:00 -07:00
Slava Kim
6b1bb038d8 Move files into tools/fs 2015-08-03 22:09:28 -07:00
Slava Kim
36b542f822 move files into tools/packaging 2015-08-03 16:03:15 -07:00
Slava Kim
9abdf1eef1 Fixes to old cli tests 2015-03-30 20:15:36 -07:00
Slava Kim
759510a584 Bump the tests timeout to fix tests on Windows
Yeah, they are slower on Windows :(
2015-03-05 17:30:20 -08:00
Sashko Stubailo
2eaa848bcc Convert __dirname to standard path 2015-02-09 13:49:57 -08:00
Avital Oliver
5570c31da7 Add clarifying comment 2015-02-04 13:25:20 -08:00
Avital Oliver
7b82a31b9b Use correct path types when using Run in selftest
Originally from a code review comment of Sashko's.
Part of this commit is making explicit the contract
for arguments passed to `Run`.
2015-02-04 13:08:04 -08:00
Avital Oliver
d174d0d134 Fix two self-tests on Windows via files.convertToOSPath 2015-02-02 10:50:44 -08:00
David Glasser
64645d8727 Fix pathwatcher fallback tests
- Future.wait does not throw
- any non-empty env var counts as true
2014-12-16 17:04:53 -08:00
Ben Newman
c3a23698fe Run file watching tests with both pathwatcher.watch and fs.watchFile.
Running the two versions of the test in parallel is safe because they run
in separate processes, and a good idea because it cuts the time taken by
the test in half, from 36sec to 19sec.
2014-12-16 19:25:25 -05:00
Sashko Stubailo
e7167e5257 Factor out almost all fs. and path. calls in the tool
This will be useful when we want to be smart with windows file paths later
Also, all of the file calls are asynchronous with fibers now, which comes with
many benefits.

This is a combination of 23 commits. Original messages:
Wrap a large number of fs calls inside files.*

Convert a few more fs calls to files.*

More moving fs.* to files

Implement read/write streams and open/read/close

Get rid of fs from auth.js

Remove fs and unused imports from catalog-local and catalog-remote

Remove unused imports from catalog.js

Replace a whole lot of fs calls

Fix error

Migrate a lot more fs. calls to files.

Add a temporary symlink method

Convert old test to files.*

Use files.pathX instead of path.x everywhere

Replace path.x to files.pathX in tests

Small fixes to files.js and one rename

Make cleanup run in a fiber

Make wrapping functions take function name in case we need it

Add some timeouts and stuff to HCP tests

wrapFsFunc also makes a sync version of the function

Sometimes you just don't want to yield!

Make sure JsImage readFromDisk doesn't yield

Remove unused imports from npm test

Change order of test now that some things don't yield

Fix missing files import, and add a debug error printout
2014-12-15 15:32:06 -08:00
Emily Stark
dcf3539f7d Remove 'old cli tests (warehouse)'.
It hasn't passed for a while and we have no plans to fix it.
2014-09-11 15:31:02 -07:00
Emily Stark
c1a5443ba7 Two small steps towards getting "old cli tests (warehouse)" to run 2014-07-22 17:14:02 -07:00
ekatek
8bb675c0b6 cleaning up some tests to run from release 2014-07-17 15:41:39 -07:00
David Glasser
d422da3584 bundler-options passes 2014-06-10 19:25:38 -07:00
David Glasser
6d3257909d test-bundler-assets passes 2014-06-10 19:13:48 -07:00
ekatek
1cf0655da4 Bundler should not take appDir and loader as arguments anymore 2014-05-30 18:32:49 -07:00
David Glasser
67bc21c0a9 pass path to node to cli-test 2014-02-06 13:30:09 -08:00
David Glasser
a74855d50a bundler-assets: find meteor 2014-02-06 12:32:07 -08:00
David Glasser
7f2eccecda more efforts to get released self-test working 2014-02-06 12:00:49 -08:00
David Glasser
576573f688 Add 'net' tag to some 'slow' tags that use npm
'meteor self-test --slow' now passes while offline
2014-02-03 10:39:48 -08:00
Geoff Schmidt
fd5073888a Rename 'self tests' directory to 'tests' 2014-01-28 16:00:46 -08:00