find projects by name - e2e

stable
Juanfran 2015-10-29 11:14:49 +01:00
parent c608d80874
commit f8d0f859b8
2 changed files with 8 additions and 2 deletions

View File

@ -13,7 +13,7 @@ describe('User story detail', function(){
before(async function(){
await utils.nav
.init()
.project(2)
.project('Project Example 0')
.backlog()
.us(0)
.go();

View File

@ -6,7 +6,13 @@ var actions = {
project: function(index) {
browser.actions().mouseMove($('div[tg-dropdown-project-list]')).perform();
let project = $$('div[tg-dropdown-project-list] li a').get(index);
let project = null;
if (typeof index === 'string' || index instanceof String) {
project = $('div[tg-dropdown-project-list]').element(by.cssContainingText('li a', index));
} else {
project = $$('div[tg-dropdown-project-list] li a').get(index);
}
common.link(project);