Skip to content

Commit

Permalink
cleaning up fixture/spec generation
Browse files Browse the repository at this point in the history
  • Loading branch information
Larry Karnowski committed Jan 23, 2009
1 parent cbcdaab commit 9a28618
Show file tree
Hide file tree
Showing 5 changed files with 94 additions and 31 deletions.
3 changes: 2 additions & 1 deletion TODO.taskpaper
Expand Up @@ -9,7 +9,8 @@ Release 1:
- change generators to use Screw.Unit style instead of JS-Spec
- improve "require" to take an array and chain then together in order @release2?
- test that env-js works with DOCTYPEs now?

- why is rake building everything twice (from command line & from TextMate)
Release 2:
- write Java code (and include jar) that allows calling print without adding an additional newline
- will require an ant build in the plugin?
- rake task to open fixtures in your favorite web browser?
Expand Up @@ -7,7 +7,7 @@ def manifest

m.directory 'test/javascript/fixtures'
m.file 'application.html', 'test/javascript/fixtures/application.html'
m.file 'js-spec.css', 'test/javascript/fixtures/js-spec.css'
m.file 'screw.css', 'test/javascript/fixtures/screw.css'
end
end
end
28 changes: 0 additions & 28 deletions generators/javascript_testing/templates/js-spec.css

This file was deleted.

90 changes: 90 additions & 0 deletions generators/javascript_testing/templates/screw.css
@@ -0,0 +1,90 @@
html {
padding: 0.5em;
font-family: Georgia, serif;
background: #EDEBD5;
}

li {
list-style-type: none;
}

.focused {
background-color: #F4F2E4;
}

.focused * {
opacity: 1.0;
}

h1, h2, p {
opacity: 0.4;
}

.describes {
padding-left: 0;
}

.describes h1 {
font-size: 1.1em;
color: #877C21;
line-height: 1.8em;
margin: 0pt 0pt 0.6em;
border-bottom: 1px solid transparent;
}

.describes h1:hover {
cursor: pointer;
color: #000;
background-color: #F4F2E4;
border-bottom: 1px solid #9A8E51;
}

.describes .describe {
margin-left: 0.6em;
padding-left: 0.6em;
border: 1px dashed #999;
}

.describes .describe .its {}

.describes .describe .its .it {
list-style-type: lower-roman;
list-style-position: outside;
}

.describes .describe .its .it h2 {
font-weight: normal;
font-style: italic;
padding-left: 0.5em;
font-size: 1.0em;
color: #877C21;
line-height: 1.8em;
margin: 0 0 0.5em;
border-bottom: 1px solid transparent;
}

.describes .describe .its .it.enqueued h2 {
background-color: #CC6600;
color: white !important;
}

.describes .describe .its .it.passed h2 {
background-color: #5A753D;
color: white !important;
}

.describes .describe .its .it.failed h2 {
background-color: #993300;
color: white !important;
}

.describes .describe .its .it.failed p {
margin-left: 1em;
color: #993300;
}

.describes .describe .its .it h2:hover {
cursor: pointer;
color: #000 !important;
border-bottom: 1px solid #9A8E51;
}
2 changes: 1 addition & 1 deletion tasks/javascript_testing_tasks.rake
@@ -1,7 +1,7 @@
namespace :test do
desc "Runs all the JSSpec tests and collects the results"
task :javascripts do
plugin_prefix = "#{RAILS_ROOT}/vendor/plugins/javascript_testing"
plugin_prefix = "#{RAILS_ROOT}/vendor/plugins/javascript_testing"
test_runner_command = "java -jar #{plugin_prefix}/lib/js.jar #{plugin_prefix}/lib/test_runner.js"

Dir.chdir("test/javascript") do
Expand Down

0 comments on commit 9a28618

Please sign in to comment.