-
Notifications
You must be signed in to change notification settings - Fork 62
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
Updated failing functional tests. #286
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There seems to be a race condition in the "Issue should edit the created comment" test case.
I ran the full suite three times out of which it failed once and passed twice.
When failed the error was a following:
1) Issue
should edit the created comment:
Error: No editor found for the root `JSHandle@node`.
at IssuePage.getEditorByRoot (tests\_pom\githubpage.js:90:10)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async IssuePage.editComment (tests\_pom\pages\commentstimelinepage.js:48:10)
at async Context.<anonymous> (tests\functional\issue.js:62:18)
Wiki unit test is also randomly failing it passed once per three runs.
Interestingly in both fails error message was different:
6) Wiki
should create a new wiki:
Error: No node found for selector: [name="wiki[name]"]
at Object.assert (node_modules\puppeteer\lib\cjs\puppeteer\common\assert.js:26:15)
at DOMWorld.type (node_modules\puppeteer\lib\cjs\puppeteer\common\DOMWorld.js:307:21)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async NewWikiPage.setTitle (tests\_pom\pages\newwikipage.js:28:3)
at async Context.<anonymous> (tests\functional\wiki.js:27:3)
and the other was:
7) Wiki
should create a new wiki:
AssertionError: expected '<p>Typing inside <strong>GitHub Writer</strong>.</p>\n<p>Time stamp: 2021-11-08T10:23:05.463Z.Welcome to the test-project wiki!</p>' to equal '<p>Typing inside <strong>GitHub Writer</strong>.</p>\n<p>Time stamp: 2021-11-08T10:23:05.463Z.</p>'
+ expected - actual
<p>Typing inside <strong>GitHub Writer</strong>.</p>
-<p>Time stamp: 2021-11-08T10:23:05.463Z.Welcome to the test-project wiki!</p>
+<p>Time stamp: 2021-11-08T10:23:05.463Z.</p>
at Context.<anonymous> (tests\functional\wiki.js:40:44)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
All five unit tests for pull request are (consistently) failing for me:
Errors are:
1) Pull Request
should create a new pull request:
Error: No root element found for the selector `form.js-blob-form`.
at FileEditPage.getEditorByRoot (tests\_pom\githubpage.js:84:10)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async FileEditPage.getMainEditor (tests\_pom\pages\fileeditpage.js:29:10)
at async FileEditPage.appendText (tests\_pom\pages\fileeditpage.js:39:18)
at async Context.<anonymous> (tests\functional\pullrequest.js:27:3)
2) Pull Request
should create a new comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:50:27)
at processImmediate (internal/timers.js:461:21)
3) Pull Request
should edit the created comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:69:27)
at processImmediate (internal/timers.js:461:21)
4) Pull Request
should add a code line comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:88:27)
at processImmediate (internal/timers.js:461:21)
5) Pull Request
should add a review comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:107:27)
at processImmediate (internal/timers.js:461:21)
2) Pull Request
should create a new pull request:
Error: No root element found for the selector `form.js-blob-form`.
at FileEditPage.getEditorByRoot (tests\_pom\githubpage.js:84:10)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async FileEditPage.getMainEditor (tests\_pom\pages\fileeditpage.js:29:10)
at async FileEditPage.appendText (tests\_pom\pages\fileeditpage.js:39:18)
at async Context.<anonymous> (tests\functional\pullrequest.js:27:3)
3) Pull Request
should create a new comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:50:27)
at processImmediate (internal/timers.js:461:21)
4) Pull Request
should edit the created comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:69:27)
at processImmediate (internal/timers.js:461:21)
5) Pull Request
should add a code line comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:88:27)
at processImmediate (internal/timers.js:461:21)
6) Pull Request
should add a review comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:107:27)
at processImmediate (internal/timers.js:461:21)
1) Pull Request
should create a new pull request:
Error: No root element found for the selector `form.js-blob-form`.
at FileEditPage.getEditorByRoot (tests\_pom\githubpage.js:84:10)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async FileEditPage.getMainEditor (tests\_pom\pages\fileeditpage.js:29:10)
at async FileEditPage.appendText (tests\_pom\pages\fileeditpage.js:39:18)
at async Context.<anonymous> (tests\functional\pullrequest.js:27:3)
2) Pull Request
should create a new comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:50:27)
at processImmediate (internal/timers.js:461:21)
3) Pull Request
should edit the created comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:69:27)
at processImmediate (internal/timers.js:461:21)
4) Pull Request
should add a code line comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:88:27)
at processImmediate (internal/timers.js:461:21)
5) Pull Request
should add a review comment:
AssertionError: expected { Object (url, needsLogin, ...) } to be an instance of PullRequestPage
at Context.<anonymous> (tests\functional\pullrequest.js:107:27)
at processImmediate (internal/timers.js:461:21)
Observations:1. When the button ( The most common error in the console is:
2. Additional checks (added while testing) inside the clickListener in the 3. Tried to add multiple specific 4. Checking the Possible fix:1. Enforce the creation of the 2. Optional tests temporary "patch":
|
Tests: Functional tests have been updated and are now working correctly. Fixes: #281.
This issue most likely will result in fixing the: #285 as well.