require statements on separate lines and travis check failires

This commit is contained in:
jwzimmer 2016-09-15 13:22:53 -04:00
parent e21a2eadb1
commit eb788acac0

View file

@ -4,8 +4,8 @@
* Test cases: https://github.com/LLK/scratch-www/wiki/Most-Important-Workflows#Create_should_take_you_to_the_editor * Test cases: https://github.com/LLK/scratch-www/wiki/Most-Important-Workflows#Create_should_take_you_to_the_editor
*/ */
var tap=require('tap'), var tap=require('tap');
seleniumWebdriver = require('selenium-webdriver'); var seleniumWebdriver = require('selenium-webdriver');
/* /*
* Remove question comments after resolving them * Remove question comments after resolving them
@ -33,7 +33,8 @@ driver.get('https://scratch.ly');
*/ */
//this xpath is fragile, can i look up by successive attributes instead? //this xpath is fragile, can i look up by successive attributes instead?
tap.test('checkCreateLinkWhenSignedOut', function (t) { tap.test('checkCreateLinkWhenSignedOut', function (t) {
var createLinkSignedOut = driver.findElement(seleniumWebdriver.By.xpath('//div[@id="navigation"]/div[@class="inner"]/ul/li[@class="link create"]/a')); var xPathLink = '//div[@id="navigation"]/div[@class="inner"]/ul/li[@class="link create"]/a';
var createLinkSignedOut = driver.findElement(seleniumWebdriver.By.xpath(xPathLink));
createLinkSignedOut.getAttribute('href').then( function (href) { createLinkSignedOut.getAttribute('href').then( function (href) {
t.equal('https://scratch.ly/projects/editor/?tip_bar=home', href); t.equal('https://scratch.ly/projects/editor/?tip_bar=home', href);
t.end(); t.end();