From 5b4e8b907633383462929fa9f0c72d4a8f23d514 Mon Sep 17 00:00:00 2001
From: Mary Bucknell <mbucknell@usgs.gov>
Date: Thu, 25 Jan 2018 12:44:00 -0600
Subject: [PATCH] All tests are passing. Have not yet added any new tests.

---
 .../scripts/components/hydrograph/index.spec.js  |  2 +-
 assets/src/scripts/models.spec.js                | 16 ++--------------
 2 files changed, 3 insertions(+), 15 deletions(-)

diff --git a/assets/src/scripts/components/hydrograph/index.spec.js b/assets/src/scripts/components/hydrograph/index.spec.js
index 70eaf0a9b..277ddd664 100644
--- a/assets/src/scripts/components/hydrograph/index.spec.js
+++ b/assets/src/scripts/components/hydrograph/index.spec.js
@@ -108,7 +108,7 @@ describe('Hydrograph charting module', () => {
                         expected = {datum: data[index + 1], index: index + 1};
                     }
                     let time = new Date(datum.time.getTime() + offset);
-                    let returned = graph._getNearestTime(time);
+                    let returned = graph._getNearestTime(time, 'current');
                     expect(returned.datum.time).toBe(expected.datum.time);
                     expect(returned.datum.index).toBe(expected.datum.index);
                 }
diff --git a/assets/src/scripts/models.spec.js b/assets/src/scripts/models.spec.js
index 406281120..0f01ef118 100644
--- a/assets/src/scripts/models.spec.js
+++ b/assets/src/scripts/models.spec.js
@@ -1,11 +1,9 @@
-var proxyquire = require('proxyquireify')(require);
+let proxyquire = require('proxyquireify')(require);
 
 
-fdescribe('Models module', () => {
+describe('Models module', () => {
 
     describe('getTimeSeries function', () => {
-        let paramCode = '00060';
-        let siteID = '05413500';
         let ajaxMock;
         let models;
 
@@ -17,9 +15,6 @@ fdescribe('Models module', () => {
                     return getPromise;
                 }
             };
-            getPromise.then((resp) => {
-                console.log('Got resp');
-            });
             models = proxyquire('./models', {'./ajax': ajaxMock});
         });
 
@@ -28,13 +23,6 @@ fdescribe('Models module', () => {
             let paramCode = '00060';
             let siteID = '05413500';
 
-            //jasmine.Ajax.stubRequest(
-            //    'https://waterservices.usgs.gov/nwis/iv/?sites=05413500&parameterCd=00060&period=P7D&indent=on&siteStatus=all&format=json').
-            //    andReturn({
-            //        'status': 200,
-            //        'contentType': 'text/json',
-            //        'responseText': MOCK_DATA  /* eslint no-use-before-define: "ignore" */
-             //   });
             models.getTimeseries({sites: [siteID], params: [paramCode]}).then((series) => {
                 expect(series.length).toBe(1);
                 expect(series[0].code).toBe(paramCode);
-- 
GitLab