Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- I want to return a function and have it evaluated in the calling module
- define(function() {
- var stage = {
- before: {
- createCanvas: function() {
- return function() {
- before(function(done) {
- this.canvas = new dropchart.Canvas({
- canvas: argsFor.canvas(),
- data: argsFor.data()
- });
- done();
- });
- };
- }
- }
- };
- return stage;
- });
- define(['jquery', 'dropchart', 'argsFor', 'stage'],
- function($, dropchart, argsFor, stage) {
- var should = chai.should();
- var xAxisSpec = {
- run: function() {
- describe('xAxis', function() {
- stage.before.createCanvas();
- ...
Advertisement
Add Comment
Please, Sign In to add comment