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

Use Jest as test runner for end to end test instead of Mocha #111

Merged
merged 1 commit into from
Jun 23, 2017

Conversation

henrywang
Copy link
Member

No description provided.

Copy link
Contributor

@atodorov atodorov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good except the comment I made but the e2e tests fail with the following error:

> jest --runInBand

 PASS  test/test_viewRecipe.js (54.575s)
 PASS  test/test_editRecipe.js (48.773s)
(node:33) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: expect(received).toBe(expected)

Expected value to be (using ===):
  "UI automation recipe"
Received:
  "Automatically Tuned Linear Algebra Software"
 FAIL  test/test_recipes.js (59.058s)
  ● Recipes Page › Recipe List › Single Word Recipe Name Scenario › Recipe Content Check #acceptance › should have correct recipe description on list after new recipe added @recipes-page

    Timeout - Async callback was not invoked within timeout specified by jasmine.DEFAULT_TIMEOUT_INTERVAL.
      
      at pTimeout (node_modules/jest-jasmine2/build/queueRunner.js:53:21)
      at Timeout.callback [as _onTimeout] (node_modules/jsdom/lib/jsdom/browser/Window.js:523:19)
      at ontimeout (timers.js:365:14)
      at tryOnTimeout (timers.js:237:5)
      at Timer.listOnTimeout (timers.js:207:5)

 PASS  test/test_createRecipe.js
 PASS  test/test_importSanity.js

Test Suites: 1 failed, 4 passed, 5 total
Tests:       1 failed, 64 passed, 65 total
Snapshots:   0 total
Time:        168.51s
Ran all test suites.

Please fix the comment and test execution and we can safely merge.

@@ -47,6 +47,7 @@
"eslint": "^3.17.1",
"eslint-config-airbnb": "^9.0.1",
"eslint-plugin-import": "^1.12.0",
"eslint-plugin-jest": "^20.0.3",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we remove the mocha plugin then ?

@coveralls
Copy link

Coverage Status

Coverage remained the same at 7.317% when pulling 76b4597 on henrywang:jest into 8ff44ba on weldr:master.

@henrywang
Copy link
Member Author

Issue resolved, mocha and chai related package deleted.

@atodorov atodorov merged commit 77b5678 into osbuild:master Jun 23, 2017
@henrywang
Copy link
Member Author

@henrywang henrywang deleted the jest branch July 12, 2017 03:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants