Extended list of users
[dygraphs.git] / auto_tests / tests / connect_separated_points.js
index c104299..7b9fe4c 100644 (file)
@@ -3,17 +3,20 @@
  *
  * @author julian.eichstaedt@ch.sauter-bc.com (Fr. Sauter AG)
  */
+
+import Dygraph from '../../src/dygraph';
+import * as utils from '../../src/dygraph-utils';
+import CanvasAssertions from './CanvasAssertions';
+import Proxy from './Proxy';
+
 describe("connect-separated-points", function() {
 
-beforeEach(function() {
-  document.body.innerHTML = "<div id='graph'></div>";
-});
+cleanupAfterEach();
 
-var origFunc = Dygraph.getContext;
+var origFunc = utils.getContext;
 
 beforeEach(function() {
-  document.body.innerHTML = "<div id='graph'></div>";
-  Dygraph.getContext = function(canvas) {
+  utils.getContext = function(canvas) {
     return new Proxy(origFunc(canvas));
   };
 });
@@ -359,7 +362,7 @@ it('testConnectSeparatedPointsPerSeries', function() {
         CanvasAssertions.numLinesDrawn(htx, "#ff0000"),
         CanvasAssertions.numLinesDrawn(htx, "#00ff00"),
         CanvasAssertions.numLinesDrawn(htx, "#0000ff")];
-    assert.equal(expected, actual);
+    assert.deepEqual(expected, actual);
   }
 
   var g = new Dygraph(document.getElementById("graph"),