2017-11-15 8 views

答えて

0

おそらくジャスミン内蔵のdone.failの可能性があります。一例として、

Read about it here

あなたの質問でジャスミンの紹介ページから、ここで、プレーンな例が欠落しています。

describe("A spec using done.fail", function() { 
    var foo = function(x, callBack1, callBack2) { 
    if (x) { 
     setTimeout(callBack1, 0); 
    } else { 
     setTimeout(callBack2, 0); 
    } 
    }; 

    it("should not call the second callBack", function(done) { 
    foo(true, 
     done, 
     function() { 
     done.fail("Second callback has been called"); 
     } 
    ); 
    }); 
}); 
関連する問題