Skip to content

Commit

Permalink
Fix: Functional tests (#193)
Browse files Browse the repository at this point in the history
  • Loading branch information
pramodsum authored May 30, 2018
1 parent a8f61ba commit 82bf717
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion functional-tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@
1) Install selenium-standalone `npm install selenium-standalone@latest -g`
2) Install Selenium drivers `selenium-standalone install`
3) Start Selenium `selenium-standalone start`
4) In a separate terminal, build Preview `yarn run build`
4) In a separate terminal, build BoxAnnotations `yarn run selenium-build`
5) Run functional tests `FILE_ID="285568802145" FILE_VERSION_ID="300497533713" yarn run functional-tests`
2 changes: 1 addition & 1 deletion functional-tests/tests/draw.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Scenario('Create/Delete drawing @desktop', function(I) {

I.say('Enter draw annotation mode');
I.click(SELECTOR_ANNOTATION_BUTTON_DRAW);
I.waitForDetached(SELECTOR_ANNOTATION_HIGHLIGHT_DIALOG);
I.dontSeeElement(SELECTOR_ANNOTATION_HIGHLIGHT_DIALOG);
I.waitForVisible('.bp-notification');
I.waitForVisible(SELECTOR_ANNNOTATION_MODE_BACKGROUND);
I.waitForVisible(SELECTOR_ANNOTATION_BUTTON_DRAW_POST);
Expand Down
8 changes: 4 additions & 4 deletions functional-tests/tests/point.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Scenario('Create/Delete point annotation @desktop', function(I) {

I.say('Enter point annotation mode');
I.click(SELECTOR_ANNOTATION_BUTTON_POINT);
I.waitForDetached(SELECTOR_ANNOTATION_HIGHLIGHT_DIALOG);
I.dontSeeElement(SELECTOR_ANNOTATION_HIGHLIGHT_DIALOG);
I.waitForVisible('.bp-notification');
I.waitForVisible(SELECTOR_ANNNOTATION_MODE_BACKGROUND);
I.waitForVisible(SELECTOR_POINT_MODE_HEADER);
Expand All @@ -58,7 +58,7 @@ Scenario('Create/Delete point annotation @desktop', function(I) {
validateTextarea(I, '[data-section="create"]', SELECTOR_ANNOTATION_TEXTAREA);

I.say('Cancel point annotation');
I.click(SELECTOR_ANNOTATION_BUTTON_CANCEL);
I.click(`[data-section="create"] ${SELECTOR_ANNOTATION_BUTTON_CANCEL}`);
I.waitForInvisible(SELECTOR_ANNOTATION_DIALOG, 1);
I.waitForInvisible(SELECTOR_ANNOTATION_POINT_MARKER, 1);

Expand All @@ -70,8 +70,8 @@ Scenario('Create/Delete point annotation @desktop', function(I) {
I.waitForVisible(SELECTOR_ANNOTATION_POINT_MARKER);

I.say('Post point annotation');
I.fillField(SELECTOR_ANNOTATION_TEXTAREA, 'Sample comment');
I.click(SELECTOR_ANNOTATION_BUTTON_POST);
I.fillField(`[data-section="create"] ${SELECTOR_ANNOTATION_TEXTAREA}`, 'Sample comment');
I.click(`[data-section="create"] ${SELECTOR_ANNOTATION_BUTTON_POST}`);
validateAnnotation(I);
I.waitNumberOfVisibleElements(SELECTOR_ANNOTATION_COMMENT, 1);

Expand Down

0 comments on commit 82bf717

Please sign in to comment.