Commit Graph

482 Commits

Author SHA1 Message Date
Wliu
cd84216f11
Merge branch 'master' into wl-rm-safe-clipboard 2018-01-09 21:39:04 -05:00
Wliu
a1668fc953
Remove old clipboard workaround on Linux 2018-01-04 20:59:32 -05:00
Max Brunsfeld
0b6e994ac6 Merge branch 'master' into mb-tree-sitter-parsers 2017-12-27 12:35:51 -08:00
Wliu
7b53a4f498
Don't require HistoryManager in spec-helper 2017-12-05 11:33:25 +01:00
Wliu
376919772b
Spy on HistoryManager prototype
To prevent other instances of HistoryManager from messing up the project
history
2017-12-05 00:47:03 +01:00
Max Brunsfeld
9762685106 Start work on loading tree-sitter grammars in GrammarRegistry 2017-11-30 09:31:08 -08:00
Max Brunsfeld
607ed74e7b Rename TokenizedBuffer to TextMateLanguageMode 2017-11-28 16:57:06 -08:00
Max Brunsfeld
afc4245971 Make TokenizedBuffer behave consistently when tokenizeInBackground is mocked 2017-11-22 15:30:28 -08:00
Wliu
ebf23ec3e1
Do not clobber recent project history when running specs 2017-11-21 21:19:05 +01:00
Nathan Sobo
364964ea0a Always assign a project path outside of bundle for legacy package specs
This prevents package specs that don't have a fixtures directory from
attempting to read files out of a non-existent directory inside the ASAR
bundle, which causes ENOTDIR errors in superstring.

If the spec does not have a parent folder containing a fixtures
directory, we now set the default project path to `os.tmpdir()`.
2017-10-25 10:34:43 -06:00
Damien Guard
69e631d509
Allow Promises to be returned by a package deactivate method 2017-09-08 19:00:25 -07:00
Nathan Sobo
f33bca4fd9 Try always mocking Date.now in our global spec helper 2017-07-31 11:21:14 -06:00
Nathan Sobo
4254825f3c Remove duplicate mocking
Since this was newly introduced, let's only set it up when clock mocking
is specifically requested to minimize breakage. We really need to
deprecate the global spec helper someday. It's bad news.

/cc @hansonw
2017-07-31 11:21:14 -06:00
Nathan Sobo
e62d1b91b7 Unspy Date.now when jasmine.useRealClock is called 2017-05-11 21:33:50 -06:00
Nathan Sobo
80f033114c Mock Date.now in spec helper in addition to _.now
Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2017-05-11 15:20:53 -06:00
Antonio Scandurra
0f6e018804 Throw an error if there is any deprecation in a spec
Previously this logic lived in atom-reporter, but it seems more
reasonable to throw errors in spec-helper instead, so that the test
suite fails in CI as well whenever a deprecated method or stylesheet is
used.
2016-10-07 10:40:41 +02:00
Indrek Ardel
55f3311c01 Remove unused variables 2016-09-26 20:52:13 +03:00
Max Brunsfeld
1c99c399d1 Merge branch 'master' into ns-mb-detangle-editor 2016-08-15 11:17:07 -07:00
Nathan Sobo
ced2174b5a Mock clock and animation frames in TextEditorComponent specs 2016-08-12 15:21:46 -06:00
Max Brunsfeld
738a2b90dc 🔥 useShadowDOM setting 2016-07-28 10:02:16 -07:00
Damien Guard
1500381ac9 Tweaks to the specs improvements from feedback 2016-04-19 14:25:44 -07:00
Damien Guard
99e716f9ed Fix specs failures on Windows including paths 2016-04-15 11:25:05 -07:00
Nathan Sobo
265aa2f6c8 Warn rather than failing if we detect leaked pathwatcher subscriptions 2016-03-29 16:46:57 -06:00
Daniel Hengeveld
281d6a66b9 Don't let label be null 2016-01-14 21:17:29 -05:00
Daniel Hengeveld
4fff6221bd Add option for custom label to waitsForPromise 2016-01-14 20:47:02 -05:00
Max Brunsfeld
327cf6997b Remember which packages use atom APIs at main module load time
Signed-off-by: Nathan Sobo <nathan@github.com>
2015-11-23 17:35:38 -08:00
Max Brunsfeld
82103f9da0 Remove unused spec-helper requires 2015-10-16 16:49:24 -07:00
Nathan Sobo
b58b3504f4 Only load/save AtomEnvironment state if persistence is enabled 2015-10-14 22:10:51 -06:00
Nathan Sobo
95dd628d42 Fix for packages with no spec/fixtures directory 2015-10-14 17:10:30 -06:00
Nathan Sobo
f0da8f6324 Resolve package names to package currently being tested
This logic existed previously, but I accidentally removed it.
2015-10-14 16:35:00 -06:00
Antonio Scandurra
4b10f8a2b0 🔥 Avoid mocking atom.config in spec-helper 2015-10-14 12:47:33 +02:00
Antonio Scandurra
b25d3e944b Parameterize configDirPath and move config.load in ctor 2015-10-14 12:41:36 +02:00
Nathan Sobo
74d644ac73 Clear GrammarRegistry in AtomEnvironment::reset 2015-10-13 20:09:56 -06:00
Nathan Sobo
3ef6a9b63b Remove workspaceParentSelector and always attach to document body
Tests never call startEditorWindow anyway.
2015-10-13 19:54:29 -06:00
Nathan Sobo
a8ca3165a0 Remove dead code 2015-10-13 14:46:28 -06:00
Nathan Sobo
f7a3e6c425 Don’t load base style sheets until config is loaded
We need to know what themes are active in order to load the correct LESS
variables.
2015-10-12 16:12:46 -06:00
Nathan Sobo
69e8b0cfb1 Prevent title change during specs 2015-10-12 15:19:55 -06:00
Nathan Sobo
29fe98581e Don’t assign atom.themes.workspace in spec-helper 2015-10-12 13:54:35 -06:00
Antonio Scandurra
56e13bba69 Reset Workspace in AtomEnvironment 2015-10-12 15:01:00 +02:00
Antonio Scandurra
5d6713f6fa Pass deserializerManager in Workspace 2015-10-11 18:11:54 +02:00
Max Brunsfeld
b467c83e76 Remove unused requires in spec-helper 2015-10-09 13:46:51 -07:00
Antonio Scandurra
60e4b78da3 Move package reset down into PackageManager 2015-10-09 10:04:04 +02:00
Max Brunsfeld
43d0241685 Reset project in AtomEnvironment::reset 2015-10-08 17:54:43 -07:00
Max Brunsfeld
4835fef7be Reset service-hub in AtomEnvironment::reset() 2015-10-08 16:29:54 -07:00
Max Brunsfeld
c268b4e050 Remove unused stylesheet cleanup in spec-helper 2015-10-08 13:11:58 -07:00
Max Brunsfeld
fb2a1284f6 Clear notifications and context menus in AtomEnvironment::reset 2015-10-08 12:41:07 -07:00
Max Brunsfeld
9664d34750 Reset MenuManager in AtomEnvironment::reset 2015-10-08 11:56:12 -07:00
Antonio Scandurra
9ac4034135 🔥 Drop --spec-directory 2015-10-08 14:04:23 +02:00
Nathan Sobo
ca0dda77b6 Don’t bind window:close in spec helper 2015-10-07 15:25:07 -05:00
Nathan Sobo
0f4558c448 Don’t load key bindings in spec helper 2015-10-07 15:25:06 -05:00