Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

nightwatch dynamic url #79

Benjamina31a020093bf
diff --git a/Gruntfile.js b/Gruntfile.js
index fc4e3072e..67f094fab 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -67,11 +67,11 @@ module.exports = function(grunt) {
nightwatch: {
options: {
// task options
-
- src_folders: ["e2e"],
+ src_folders: ["./e2e/tests"],
standalone: true,
// download settings
jar_version: '3.0.1',
+ globals_path: "./e2e/globals.js",
selenium_port: 4444,
server_path: "node_modules/selenium-server-standalone-jar/jar/selenium-server-standalone-3.0.1.jar",
test_settings: {
diff --git a/e2e/globals.js b/e2e/globals.js
new file mode 100644
index 000000000..8bb7e5fa7
--- /dev/null
+++ b/e2e/globals.js
@@ -0,0 +1,3 @@
+module.exports = {
+ url: 'https://worldview.sit.earthdata.nasa.gov/'
+}
\ No newline at end of file
diff --git a/e2e/anim.gif.js b/e2e/tests/anim.gif.js
similarity index 82%
rename from e2e/anim.gif.js
rename to e2e/tests/anim.gif.js
index bbc9475cc..00a13f970 100644
--- a/e2e/anim.gif.js
+++ b/e2e/tests/anim.gif.js
@@ -2,7 +2,7 @@ module.exports = {
'Animation GIF tests' : function (browser) {
var startDay, newDay;
browser
- .url('http://go.nasa.gov/2fEDNUd')
+ .url(browser.globals.url + '?p=geographic&l=VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor,Reference_Labels(hidden),Reference_Features(hidden),Coastlines&t=2016-11-28&z=1&v=-209.109375,-63.421875,148.078125,69.890625&ab=on&as=2013-11-21&ae=2016-11-28&av=3&al=false')
.pause(1000);
/*
* Should not show Tour
diff --git a/e2e/anim.js b/e2e/tests/anim.js
similarity index 96%
rename from e2e/anim.js
rename to e2e/tests/anim.js
index b12500704..a5f158234 100644
--- a/e2e/anim.js
+++ b/e2e/tests/anim.js
@@ -2,7 +2,7 @@ module.exports = {
'Animation tests' : function (browser) {
var startDay, newDay;
browser
- .url('https://worldview.sit.earthdata.nasa.gov/')
+ .url(browser.globals.url)
.pause(1000);
browser.waitForElementVisible('#skipTour', 1000, function (el) {
browser.click('#skipTour');