-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up Jasmine jQuery with an example test.
- Loading branch information
Rishabh Rao
committed
May 6, 2016
1 parent
4913fb3
commit 4684fd0
Showing
4 changed files
with
56 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<aside data-js="voxelDrawer hello" class="voxel-drawer"> | ||
</aside> <!-- /.voxel-drawer --> | ||
|
||
<header class="voxel-header"> | ||
<a href="javascript:;" data-js="voxelDrawerToggle" class="voxel-drawer__toggle">⋮</a> | ||
<div class="voxel-layout__content"> | ||
<a href="#" class="voxel-header__title" data-js="voxelDrawerHeaderTitle"> | ||
<span class="voxel-header__title__sub"></span> | ||
</a> | ||
</div> <!-- /.voxel-layout__content --> | ||
</header> <!-- /.voxel-header --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
define(function(require) { | ||
"use strict"; | ||
|
||
var jQ = require("jquery"); | ||
var JasminejQuery = require("jasmine-jquery"); | ||
|
||
var Drawer = require("components/drawer"); | ||
|
||
describe("Drawer", function() { | ||
beforeEach(function() { | ||
jasmine.getFixtures().fixturesPath = "/base/tests/components"; | ||
loadFixtures("drawer/drawer-fixture.html"); | ||
|
||
var drawer = Drawer.create({ | ||
name: "Voxel.Drawer", | ||
closeOnPageTouch: false | ||
}); | ||
}); | ||
|
||
it("loadFixtures() should load fixtures", function() { | ||
var voxelDrawer = jQ("[data-js~='voxelDrawer']"); | ||
|
||
expect(voxelDrawer.length).toEqual(1); | ||
}); | ||
|
||
it("Should spec 2", function() { | ||
}); | ||
|
||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters