forked from jasmine/jasmine
-
Notifications
You must be signed in to change notification settings - Fork 0
A simple project
Gregg Van Hove edited this page Dec 9, 2015
·
12 revisions
To use Jasmine with a simple project, download the standalone distribution for the desired version of Jasmine from the jasmine releases page. Edit the SpecRunner.html file (located in the root of your jasmine standalone download):
- add your source files as separate
<script>
tags before the Jasmine files to the head element - add your spec files as separate
<script>
tags after the Jasmine files to the head element - All paths pointing to lib/jasmine-jasmine-1.1.0.rc1, if any, should point to the parent directory. E.g.: lib/jasmine-1.1.0.rc1/jasmine.js should point to ../jasmine.js
Point your favorite browser to the SpecRunner.html
file and reload to run your specs.
As you add new files to your project, make sure to add source and spec <script>
tags.
If you get tired of managing your files manually check out how to use Jasmine in A ruby project (with or without rails) (or a project that doesn't mind having Ruby around).