summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authormo khan <mo@mokhan.ca>2013-06-02 19:55:48 -0600
committermo khan <mo@mokhan.ca>2013-06-02 19:55:48 -0600
commit7b7e3d01ef465ca05d32842c14b8fc236faec375 (patch)
tree432017bb56f760c65d33854f72dd3fc0f33337b3 /lib
parent1290b84a6f38d3d3304a183fa5a50896591fe0f3 (diff)
create ci task to run rspec and jasmine tests
Diffstat (limited to 'lib')
-rw-r--r--lib/tasks/ci.rake1
-rw-r--r--lib/tasks/js.rake10
-rw-r--r--lib/tasks/test.rake20
3 files changed, 11 insertions, 20 deletions
diff --git a/lib/tasks/ci.rake b/lib/tasks/ci.rake
new file mode 100644
index 00000000..382f5cae
--- /dev/null
+++ b/lib/tasks/ci.rake
@@ -0,0 +1 @@
+task :ci => ['db:test:prepare', 'spec', 'js:default']
diff --git a/lib/tasks/js.rake b/lib/tasks/js.rake
new file mode 100644
index 00000000..ca085440
--- /dev/null
+++ b/lib/tasks/js.rake
@@ -0,0 +1,10 @@
+namespace :js do
+ task :jasmine, [ :display ] => :environment do |t, args|
+ ENV['DISPLAY'] = args[:display] if args[:display]
+ sh("bundle exec rake jasmine:ci")
+ end
+
+ task :default, [ :display ] => :environment do |t, args|
+ Rake::Task['js:jasmine'].invoke(args[:display])
+ end
+end
diff --git a/lib/tasks/test.rake b/lib/tasks/test.rake
deleted file mode 100644
index 7c0ecd3a..00000000
--- a/lib/tasks/test.rake
+++ /dev/null
@@ -1,20 +0,0 @@
-namespace :test do
- task :specs, [ :display ] => :environment do |t, args|
- ENV['DISPLAY'] = args[:display] if args[:display]
- Rake::Task['spec:suite:all'].invoke
- end
-
- task :jasmine, [ :display ] => :environment do |t, args|
- ENV['DISPLAY'] = args[:display] if args[:display]
- sh("bundle exec rake jasmine:ci")
- end
-
- task :all, [ :display ] => :environment do |t, args|
- Rake::Task['test:jasmine'].invoke(args[:display])
- Rake::Task['test:specs'].invoke(args[:display])
- end
-
- task :ci do
- Rake::Task['test:all'].invoke(":99")
- end
-end