2015-01-20 81 views
0

我正在写一个Ruby gem,我在其中提供了许多角度指令。如何手动测试用CoffeeScript编写的AngularJS指令和Jasmine测试?

指令是使用以下文件夹结构编写的,例如,

app 
- assets 
    - javascripts 
    - components 
     - dropdown 
      - dropdown.html 
      - dropdown.service.coffee 
      - index.coffee (this has directive code) 
spec 
- javascripts 
    - dropdown 
    - dropdown.service_spec.coffee (jasmine test) 

现在既然这是一个宝石,我想保持它,而不是让它成为一个Rails应用程序。它会让人们难以用它作为宝石

但我想能够测试指令。我无法自动完成。

我想知道如何通过启动HTML页面以本地/手动方式运行这些用coffeescript编写的Jasmine测试?

回答