projects
/
dygraphs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Bump to version 2 🎉
[dygraphs.git]
/
auto_tests
/
tests
/
simple_drawing.js
diff --git
a/auto_tests/tests/simple_drawing.js
b/auto_tests/tests/simple_drawing.js
index
bda0e84
..
2ef84f3
100644
(file)
--- a/
auto_tests/tests/simple_drawing.js
+++ b/
auto_tests/tests/simple_drawing.js
@@
-24,21
+24,19
@@
* @author konigsberg@google.com (Robert Konigsberg)
*/
* @author konigsberg@google.com (Robert Konigsberg)
*/
-describe("simple-drawing", function() {
+import Dygraph from '../../src/dygraph';
+import * as utils from '../../src/dygraph-utils';
-var ZERO_TO_FIFTY = 'X,Y\n10,0\n20,50';
+import CanvasAssertions from './CanvasAssertions';
+import Proxy from './Proxy';
+import PixelSampler from './PixelSampler';
-var _origFunc = Dygraph.getContext;
-beforeEach(function() {
- document.body.innerHTML = "<div id='graph'></div>";
- Dygraph.getContext = function(canvas) {
- return new Proxy(_origFunc(canvas));
- }
-});
+describe("simple-drawing", function() {
-afterEach(function() {
- Dygraph.getContext = _origFunc;
-});
+cleanupAfterEach();
+useProxyCanvas(utils, Proxy);
+
+var ZERO_TO_FIFTY = 'X,Y\n10,0\n20,50';
it('testDrawSimpleRangePlusOne', function() {
var opts = {
it('testDrawSimpleRangePlusOne', function() {
var opts = {