Skip to content

Commit

Permalink
test(e2e): improve HooksRunner.spec (#825)
Browse files Browse the repository at this point in the history
* test(HooksRunner): properly setup temp dir

* test(HooksRunner): faster & simpler project setup

This is possible since we don't need an installed platform anymore
since we have dropped Test#012. We also needed to stop using
`util.preProcessOptions` because that expects platforms too. However,
its usage was irrelevant for the tests anyway.

* test(HooksRunner): remove unused hooks

* test(HooksRunner): reduce number of fixture files

* test(HooksRunner): make hook fixtures executable

* test(HooksRunner): cleanup & clarify "nohooks" tests

This also groups all "nohooks" tests in one describe block.

* test(HooksRunner): move tests to suitable block

* test(HooksRunner): only pass options where needed

* test(HooksRunner): cleanup "event handler" tests

- proper common test setup
- improve test descriptions
- test what the descriptions say
- replace the two last tests with a useful one
  • Loading branch information
raphinesse committed Jan 12, 2020
1 parent f53dd4a commit 214dca1
Show file tree
Hide file tree
Showing 31 changed files with 117 additions and 510 deletions.
288 changes: 116 additions & 172 deletions integration-tests/HooksRunner.spec.js

Large diffs are not rendered by default.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

12 changes: 0 additions & 12 deletions spec/cordova/fixtures/projWithHooks/config.xml

This file was deleted.

Empty file.
Empty file.

This file was deleted.

This file was deleted.

This file was deleted.

14 changes: 0 additions & 14 deletions spec/cordova/fixtures/projWithHooks/www/config.xml

This file was deleted.

115 changes: 0 additions & 115 deletions spec/cordova/fixtures/projWithHooks/www/css/index.css

This file was deleted.

Binary file removed spec/cordova/fixtures/projWithHooks/www/img/logo.png
Binary file not shown.
43 changes: 0 additions & 43 deletions spec/cordova/fixtures/projWithHooks/www/index.html

This file was deleted.

50 changes: 0 additions & 50 deletions spec/cordova/fixtures/projWithHooks/www/js/index.js

This file was deleted.

68 changes: 0 additions & 68 deletions spec/cordova/fixtures/projWithHooks/www/spec.html

This file was deleted.

File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module.exports = () => {
throw new Error();
};
};
File renamed without changes.

0 comments on commit 214dca1

Please sign in to comment.