codecombat/test/app/lib/router.spec.coffee

11 lines
348 B
CoffeeScript
Raw Normal View History

2014-01-03 13:32:13 -05:00
describe 'Router', ->
Router = require 'lib/Router'
2014-01-12 16:29:42 -05:00
xit 'caches the home view', ->
2014-01-03 13:32:13 -05:00
router = new Router()
router.openRoute('home')
2014-01-12 16:29:42 -05:00
#currentView doesn't exist
2014-01-03 13:32:13 -05:00
expect(router.cache['home']).toBe(router.currentView)
home = router.currentView
router.openRoute('home')
expect(router.cache['home']).toBe(router.currentView)