Skip to content

Commit

Permalink
Add e2e test to visit the links in the about dropdown (oppia#3223)
Browse files Browse the repository at this point in the history
arku authored and seanlip committed Mar 20, 2017
1 parent 9d754f8 commit 18e45b4
Showing 2 changed files with 10 additions and 6 deletions.
15 changes: 9 additions & 6 deletions core/tests/protractor/staticPagesTour.js
Original file line number Diff line number Diff line change
@@ -25,15 +25,18 @@ describe('Oppia static pages tour', function() {
});

it('visits the links in About dropdown', function() {
var dropdown = element(by.css('.protractor-test-about-oppia-list-item'));
var linkClassNames = ['.protractor-test-about-link',
'.protractor-test-teach-link',
'.protractor-test-contact-link'
];
var LINKS_CLASS_NAMES = [
'.protractor-test-about-link',
'.protractor-test-get-started-link',
'.protractor-test-teach-link',
'.protractor-test-contact-link'
];

linkClassNames.forEach(function(className) {
LINKS_CLASS_NAMES.forEach(function(className) {
var dropdown = element(by.css('.protractor-test-about-oppia-list-item'));
browser.actions().mouseMove(dropdown).perform();
dropdown.element(by.css(className)).click();
general.waitForSystem();
});
});

1 change: 1 addition & 0 deletions core/tests/protractor_utils/editor.js
Original file line number Diff line number Diff line change
@@ -1391,6 +1391,7 @@ var acceptSuggestion = function(suggestionDescription) {
});

matchingSuggestionRows[0].click();
general.waitForSystem();
element(by.css('.protractor-test-view-suggestion-btn')).click();
element(by.css('.protractor-test-exploration-accept-suggestion-btn')).
click();

0 comments on commit 18e45b4

Please sign in to comment.