Changeset 5072
- Timestamp:
- 09/08/06 12:27:09 (2 years ago)
- Files:
-
- plugins/javascript_test/CHANGELOG (modified) (1 diff)
- plugins/javascript_test/generators/javascript_test/templates/javascript_test.html (modified) (1 diff)
- plugins/javascript_test/README (modified) (1 diff)
- plugins/javascript_test/tasks/javascript_test.rake (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
plugins/javascript_test/CHANGELOG
r5071 r5072 1 1 *SVN* 2 3 * Allow for manual execution of tests by manually providing an assets symlink (see README) 2 4 3 5 * Updated CSS and generator to more Railsy layout and colors, borrowed from Tom Werners' #6036 default error pages patch plugins/javascript_test/generators/javascript_test/templates/javascript_test.html
r5071 r5072 5 5 <title>JavaScript unit test file</title> 6 6 <meta http-equiv="content-type" content="text/html; charset=utf-8" /> 7 <script src=" /assets/prototype.js" type="text/javascript"></script>8 <script src=" /assets/unittest.js" type="text/javascript"></script>7 <script src="assets/prototype.js" type="text/javascript"></script> 8 <script src="assets/unittest.js" type="text/javascript"></script> 9 9 10 <script src=" /javascripts/<%= name %>.js" type="text/javascript"></script>10 <script src="../../public/javascripts/<%= name %>.js" type="text/javascript"></script> 11 11 12 <link rel="stylesheet" href=" /assets/unittest.css" type="text/css" />12 <link rel="stylesheet" href="assets/unittest.css" type="text/css" /> 13 13 </head> 14 14 <body> plugins/javascript_test/README
r5060 r5072 28 28 You have to manually close the browser window(s) afterwards. 29 29 30 You can also run the test manually, by symlinking the assets directory. 31 In your Rails application root, run: 32 33 ln -s ../../vendor/plugins/javascript_test/assets/ test/javascript/assets 34 35 You then can just open the individual .html test files in your browser. 36 30 37 All in all, unittest.js is closely modelled on Test::Unit and there's 31 38 also experimental support for RSpec-style BDD testing. You can find lots plugins/javascript_test/tasks/javascript_test.rake
r5059 r5072 3 3 JavaScriptTestrunner.new do |t| 4 4 5 t.mount( '/assets', RAILS_ROOT+'/vendor/plugins/javascript_test/assets')5 t.mount("/", RAILS_ROOT) 6 6 t.mount("/test", RAILS_ROOT+'/test') 7 t.mount( "/javascripts", RAILS_ROOT+'/public/javascripts')7 t.mount('/test/javascript/assets', RAILS_ROOT+'/vendor/plugins/javascript_test/assets') 8 8 9 9 Dir.glob('test/javascript/*_test.html').each do |js|