From c47dbac87abd63b883197c64d13ad42ab9777bd8 Mon Sep 17 00:00:00 2001 From: Cherif BOUCHELAGHEM Date: Wed, 30 Oct 2019 16:21:56 +0100 Subject: [PATCH] Landscaper: Migrate to Qunit2 --- package.json | 2 +- src/test/tabs_test.js | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 819bb76..e18fb0e 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "jquery": ">1.9.0", "steal": "0.6.0-pre.0", "steal-tools": "0.6.0-pre.2", - "steal-qunit": "0.0.2", + "steal-qunit": "^2.0.0", "testee": "^0.1.8" }, "system": { diff --git a/src/test/tabs_test.js b/src/test/tabs_test.js index 1d2314c..8b701f4 100644 --- a/src/test/tabs_test.js +++ b/src/test/tabs_test.js @@ -5,22 +5,22 @@ import $ from "jquery"; QUnit.module("can-tabs view model"); -QUnit.test("basics", function(){ +QUnit.test("basics", function(assert) { var tabsVM = new CanTabsVM(); var panelVM = new CanPanelVM(); tabsVM.addPanel(panelVM); - equal(panelVM.attr("active"), true, "first panel added is active"); + assert.equal(panelVM.attr("active"), true, "first panel added is active"); }); var template = can.stache("Hello!"); QUnit.module("can-tabs component",{ - setup: function(){ + beforeEach: function(assert) { $("#qunit-fixture").append(template()); } }); -QUnit.test("basics", function(){ - QUnit.equal( $.trim( $("can-tabs ul li").text() ),"First", "has text"); +QUnit.test("basics", function(assert) { + assert.equal( $.trim( $("can-tabs ul li").text() ),"First", "has text"); });