Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
8af93229
Commit
8af93229
authored
Dec 05, 2012
by
valera-rozuvan
Committed by
Valera Rozuvan
Jan 03, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Work on RequireJS Jasmine test.
parent
7cf848db
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
11 deletions
+17
-11
lms/static/coffee/spec/requirejs_spec.coffee
+17
-11
No files found.
lms/static/coffee/spec/requirejs_spec.coffee
View file @
8af93229
describe
"RequireJS"
,
->
describe
"RequireJS"
,
->
it
"check that the RequireJS object is present in the global namespace"
,
->
beforeEach
->
expect
(
RequireJS
).
toEqual
jasmine
.
any
(
Object
)
@
addMatchers
requirejsTobeUndefined
:
->
expect
(
window
.
RequireJS
).
toEqual
jasmine
.
any
(
Object
)
typeof
requirejs
is
"undefined"
it
"check that requirejs(), require(), and define() are not in the global namespace"
,
->
expect
(
requirejs
).
not
.
toBeDefined
()
it
"check that the RequireJS object is present in the global namespace"
,
->
expect
(
require
).
not
.
toBeDefined
()
expect
(
RequireJS
).
toEqual
jasmine
.
any
(
Object
)
expect
(
define
).
not
.
toBeDefined
()
expect
(
window
.
RequireJS
).
toEqual
jasmine
.
any
(
Object
)
expect
(
window
.
requirejs
).
not
.
toBeDefined
()
expect
(
window
.
require
).
not
.
toBeDefined
()
it
"check that requirejs(), require(), and define() are not in the global namespace"
,
->
expect
(
window
.
define
).
not
.
toBeDefined
()
expect
({}).
requirejsTobeUndefined
()
# expect(require).not.toBeDefined();
# expect(define).not.toBeDefined();
expect
(
window
.
requirejs
).
not
.
toBeDefined
()
expect
(
window
.
require
).
not
.
toBeDefined
()
expect
(
window
.
define
).
not
.
toBeDefined
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment