selenium-core-runner 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,21 +1,39 @@
1
1
  = selenium-core-runner
2
2
 
3
- *Selenium Core runner for rails3
3
+ Selenium Core runner for Ruby on Rails 3.
4
4
 
5
- Put test suites and cases created on Selenium IDE into test/selenium.
6
- Access to /selenium-core-runner
5
+ You can run the test suite generated from Selenium IDE on browser using Selenium Core!
6
+
7
+
8
+ == INSTALL
9
+
10
+ * Append to your Gemfile
11
+
12
+ gem 'selenium-core-runner'
13
+
14
+ * Then bundle install
15
+
16
+ $ bundle install
17
+
18
+
19
+ == SYNOPSIS
20
+
21
+ Put test suites and cases generated from Selenium IDE into test/selenium.
7
22
 
8
23
  Assumed structure in test/selenium.
9
24
 
10
- test
11
- selenium/
12
- test_suite_name (test suite)
13
- test_suite_name/
14
- test_case1.html
15
- test_case2.html
16
- .
17
- .
18
- .
25
+ test
26
+ selenium/
27
+ test_suite_name.html (test suite)
28
+ test_suite_name/
29
+ test_case1.html
30
+ test_case2.html
31
+ .
32
+ .
33
+ .
34
+
35
+ Access to http://example.com/selenium-core-runner
19
36
 
37
+ == LICENSE
20
38
 
21
39
  This project rocks and uses MIT-LICENSE.
@@ -1,9 +1,14 @@
1
1
  module SeleniumCoreRunner
2
2
  class SuitesController < ApplicationController
3
+ layout :layout
3
4
  private
4
5
  def suites_dir
5
6
  Rails.root.to_s+"/test/selenium"
6
7
  end
8
+ def layout
9
+ return 'application' if SeleniumCoreRunner.layout==:default
10
+ SeleniumCoreRunner.layout || false
11
+ end
7
12
  public
8
13
  def list
9
14
  @suites = []
@@ -25,8 +30,8 @@ module SeleniumCoreRunner
25
30
 
26
31
  def show
27
32
  path = params[:suite]
28
- path += "."+params[:format] unless params[:format].blank?
29
33
  path += "/"+params[:case] unless params[:case].blank?
34
+ path += "."+params[:format] unless params[:format].blank?
30
35
  open(Rails.root.to_s+"/test/selenium/#{path}") {|f|
31
36
  render :text=>f.read , :layout=>false
32
37
  }
@@ -1,3 +1,3 @@
1
- <%@suites.each{|suite|%>
2
- <%=link_to suite, selenium_core_runner_path(:suite=>suite) %>
3
- <%}%>
1
+ <ul><%@suites.each{|suite|%>
2
+ <li><%=link_to suite, selenium_core_runner_path(:suite=>suite) %></li>
3
+ <%}%></ul>
@@ -1,3 +1,12 @@
1
- module SeleniumWebRunner
1
+ module SeleniumCoreRunner
2
+ @@layout = false
2
3
  require 'selenium-core-runner/engine' if defined?(Rails)
4
+
5
+ def self.layout=(layout)
6
+ @@layout = layout
7
+ end
8
+
9
+ def self.layout
10
+ @@layout
11
+ end
3
12
  end
@@ -2,7 +2,7 @@
2
2
  require "selenium-core-runner"
3
3
  require "rails"
4
4
 
5
- module SeleniumWebRunner
5
+ module SeleniumCoreRunner
6
6
  class Engine < Rails::Engine
7
7
  initializer "static assets" do |app|
8
8
  app.middleware.use ::ActionDispatch::Static, "#{root}/public"
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: selenium-core-runner
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.4
5
+ version: 0.0.5
6
6
  platform: ruby
7
7
  authors: []
8
8
 
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-04-25 00:00:00 Z
13
+ date: 2011-04-27 00:00:00 Z
14
14
  dependencies: []
15
15
 
16
16
  description: Insert SeleniumCoreRunner description.