-
Notifications
You must be signed in to change notification settings - Fork 30
/
Copy pathtest.js
84 lines (66 loc) · 2.79 KB
/
test.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
/*global describe, it, beforeEach */
'use strict';
var assert = require('chai').assert;
describe('google-cdn-data', function () {
beforeEach(function () {
this.data = require('./index');
});
describe('jQuery libraries', function () {
it('should include jquery 2.1.0', function () {
assert.include(this.data.jquery.versions, '2.1.0');
});
it('should build jquery 2.1.0 url', function () {
assert.equal(this.data.jquery.url('2.1.0'), '//ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js');
});
});
describe('jQuery UI libraries', function () {
it('should include jquery-ui 1.10.4', function () {
assert.include(this.data['jquery-ui'].versions, '1.10.4');
});
it('should build jquery-ui 1.10.4 url', function () {
assert.equal(this.data['jquery-ui'].url('1.10.4'), '//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js');
});
});
describe('Dojo libraries', function () {
it('should include dojo 1.9.2', function () {
assert.include(this.data.dojo.versions, '1.9.2');
});
it('should build dojo 1.9.2 url', function () {
assert.equal(this.data.dojo.url('1.9.2'), '//ajax.googleapis.com/ajax/libs/dojo/1.9.2/dojo/dojo.js');
});
});
describe('SWFObject libraries', function () {
it('should include swfobject 2.2', function () {
assert.include(this.data.swfobject.versions, '2.2');
});
it('should build swfobject 2.2 url', function () {
assert.equal(this.data.swfobject.url('2.2'), '//ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js');
});
});
describe('AngularJS libraries', function () {
it('should include angular 1.2.16', function () {
assert.include(this.data['angular'].versions, '1.2.16');
});
it('should include angular-animate 1.2.16', function () {
assert.include(this.data['angular-animate'].versions, '1.2.16');
});
it('should include angular-cookies 1.2.16', function () {
assert.include(this.data['angular-cookies'].versions, '1.2.16');
});
it('should include angular-loader 1.2.16', function () {
assert.include(this.data['angular-loader'].versions, '1.2.16');
});
it('should include angular-resource 1.2.16', function () {
assert.include(this.data['angular-resource'].versions, '1.2.16');
});
it('should include angular-route 1.2.16', function () {
assert.include(this.data['angular-route'].versions, '1.2.16');
});
it('should include angular-sanitize 1.2.16', function () {
assert.include(this.data['angular-sanitize'].versions, '1.2.16');
});
it('should build angular-resource 1.2.16 url', function () {
assert.equal(this.data['angular-resource'].url('1.2.16'), '//ajax.googleapis.com/ajax/libs/angularjs/1.2.16/angular-resource.min.js');
});
});
});