riot_on_rails 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore ADDED
@@ -0,0 +1,5 @@
1
+ *.gem
2
+ .bundle
3
+ Gemfile.lock
4
+ pkg/*
5
+ vendor
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source "http://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in riot_on_rails.gemspec
4
+ gemspec
data/MIT-LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2011 Lucas HĂșngaro
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.textile ADDED
@@ -0,0 +1,79 @@
1
+ h1. Riot on Rails
2
+
3
+ Hooks the Riot testing framework into Ruby on Rails.
4
+
5
+ Riot on Rails is a really small set of code to make developing Rails apps with Riot easier. No extra macros or helpers provided, just the bare basics.
6
+
7
+ Does Riot on Rails helps your daily work with Ruby? So, "please recommend me in Work With Rails":http://workingwithrails.com/recommendation/new/person/9370-lucas-h-ngaro and thanks for your kindness! :)
8
+
9
+ h2. Why?
10
+
11
+ There's already "riot-rails":https://github.com/thumblemonks/riot-rails but it's too much for my needs. I don't use macros as they hook into internals and use a lot of reflection on structure, and BDD is all about behavior. So, yes, I do write all the test code for ActiveRecord validations and relationships without macros and, hey, I'm still alive! ;)
12
+
13
+ h2. How?
14
+
15
+ Just add riot_on_rails into your Gemfile:
16
+
17
+ <pre>
18
+ group :test do
19
+ gem "riot_on_rails"
20
+ end
21
+ </pre>
22
+
23
+ For runtime, it depends on "database_cleaner":https://github.com/bmabey/database_cleaner for, wait for it, cleaning up your database, and "rack-test":https://github.com/brynary/rack-test for controller testing. These gems will be installed by Bundler.
24
+
25
+ You can disable database_cleaner this way:
26
+
27
+ <pre>
28
+ RiotOnRails.database_cleaner = false # true by default
29
+ </pre>
30
+
31
+ I opted for database_cleaner instead of hooking into ActiveRecord transactions because this way the gem provides much more flexibility (you can use other ORMs and cleaning strategies) and is less brittle (doesn't breaks if ActiveRecord changes).
32
+
33
+ You can also disable database_cleaner for specific contexts, like this:
34
+
35
+ <pre>
36
+ context "my context" do
37
+ set :skip_database_cleaner, true
38
+
39
+ # tests, tests, tests
40
+ end
41
+ </pre>
42
+
43
+ You cannot disable rack-test being included into your contexts. If you don't want to use it, there's really no reason to use this gem. :)
44
+
45
+ Riot on Rails doesn't work on Rails 2.x or older versions.
46
+
47
+ Testing models is as simple as testing any pure Ruby class, no fuzz. To test controllers you can now rely on Rack::Test API. A simple example follows:
48
+
49
+ <pre>
50
+ context HomeController do
51
+ context "site index" do
52
+ setup { get "/" }
53
+
54
+ asserts(:status).equals(200)
55
+ asserts("says hello!") { last_response.body =~ /hello/ }
56
+ end
57
+ end
58
+ </pre>
59
+
60
+ For integration test I recommend using "melee":https://github.com/achiu/melee and "capybara":https://github.com/jnicklas/capybara.
61
+
62
+ h2. Note on Patches/Pull Requests
63
+
64
+ * Fork the project.
65
+ * Make your feature addition or bug fix.
66
+ * Add tests for it. This is important so I don't break it in a
67
+ future version unintentionally.
68
+ * Commit, do not mess with rakefile, version, or history.
69
+ (if you want to have your own version, that is fine but bump version in a commit by itself so I can ignore when I pull)
70
+ * Send me a pull request. Bonus points for topic branches.
71
+
72
+ h2. Contributors
73
+
74
+ Includes code from "Padrino's":http://www.padrinorb.com generators and "riot-rails":https://github.com/thumblemonks/riot-rails
75
+
76
+ h3. License
77
+
78
+ sentinel is released under the MIT license. See "MIT LICENSE":https://github.com/lucashungaro/riot_on_rails/blob/master/MIT-LICENSE.
79
+
data/Rakefile ADDED
@@ -0,0 +1,11 @@
1
+ require 'bundler'
2
+ Bundler::GemHelper.install_tasks
3
+
4
+ task :default => [:test]
5
+
6
+ require 'rake/testtask'
7
+ Rake::TestTask.new(:test) do |test|
8
+ test.libs << 'lib' << 'test'
9
+ test.pattern = 'test/**/*_test.rb'
10
+ test.verbose = false
11
+ end
@@ -0,0 +1,13 @@
1
+ module RiotOnRails
2
+ class << self
3
+ def database_cleaner=(value)
4
+ @using_database_cleaner = value
5
+ end
6
+
7
+ def using_database_cleaner?
8
+ @using_database_cleaner
9
+ end
10
+ end
11
+ end
12
+
13
+ RiotOnRails.database_cleaner = true
@@ -0,0 +1,26 @@
1
+ module RiotOnRails
2
+ class DatabaseCleanerMiddleware < Riot::ContextMiddleware
3
+ register
4
+
5
+ def call(context)
6
+ setup_database_cleaner(context) if clean_database?(context)
7
+ middleware.call(context)
8
+ end
9
+
10
+ private
11
+ def root_context?(context)
12
+ context.parent.kind_of? Riot::RootContext
13
+ end
14
+
15
+ def clean_database?(context)
16
+ RiotOnRails.using_database_cleaner? &&
17
+ (not context.option(:skip_database_cleaner)) &&
18
+ root_context?(context)
19
+ end
20
+
21
+ def setup_database_cleaner(context)
22
+ context.setup(true) { DatabaseCleaner.start }
23
+ context.teardown { DatabaseCleaner.clean }
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,9 @@
1
+ module RiotOnRails
2
+ class Riot::Situation
3
+ include Rack::Test::Methods
4
+
5
+ def app
6
+ Rails.application
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,3 @@
1
+ module RiotOnRails
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,6 @@
1
+ require "riot"
2
+ require "database_cleaner"
3
+ require "rack/test"
4
+ require "riot_on_rails/configuration"
5
+ require "riot_on_rails/database_cleaner_middleware"
6
+ require "riot_on_rails/setup_controller_tests"
@@ -0,0 +1,34 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "riot_on_rails/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "riot_on_rails"
7
+ s.version = RiotOnRails::VERSION
8
+ s.platform = Gem::Platform::RUBY
9
+ s.authors = ["Lucas HĂșngaro"]
10
+ s.email = ["lucashungaro@gmail.com"]
11
+ s.homepage = "https://github.com/lucashungaro/riot_on_rails"
12
+ s.summary = %q{Hooks the Riot testing framework into Ruby on Rails}
13
+ s.description = %q{A set of utilities to make developing Rails apps with Riot easier.
14
+ No extra macros or helpers provided, just the bare basics.}
15
+
16
+ s.rubyforge_project = "riot_on_rails"
17
+
18
+ s.files = `git ls-files`.split("\n")
19
+ s.test_files = `git ls-files -- test/*`.split("\n")
20
+ s.require_paths = ["lib"]
21
+
22
+ s.required_rubygems_version = ">= 1.3.6"
23
+
24
+ # These gems are required for runtime and development :)
25
+ s.add_dependency("riot", "~> 0.12.4")
26
+ s.add_dependency("rack-test", "~> 0.5.7")
27
+ s.add_dependency("database_cleaner", "~> 0.6.7")
28
+
29
+ s.add_development_dependency("rake", "~> 0.8.7")
30
+ s.add_development_dependency("rr", "~> 1.0.2")
31
+ s.add_development_dependency("activerecord", ">= 3.0.0")
32
+ s.add_development_dependency("sqlite3", "~> 1.3.3")
33
+ s.add_development_dependency("rails", ">= 3.0.0")
34
+ end
@@ -0,0 +1,40 @@
1
+ require "teststrap"
2
+
3
+ context RiotOnRails::DatabaseCleanerMiddleware do
4
+ context "when configured to clean the database" do
5
+ setup do
6
+ Riot::Context.new("test context root") { Riot::Context.new("test context child") { } }
7
+ end
8
+
9
+ should("start and rollback the transaction for the root context") do
10
+ mock(DatabaseCleaner).start.once
11
+ mock(DatabaseCleaner).clean.once
12
+ topic.local_run(Riot::SilentReporter.new, Riot::Situation.new)
13
+ end
14
+ end
15
+
16
+ context "when configured to skip database_cleaner" do
17
+ setup do
18
+ RiotOnRails.database_cleaner = false
19
+ Riot::Context.new("test context root") { Riot::Context.new("test context child") { } }
20
+ end
21
+
22
+ should("start and rollback the transaction for the root context") do
23
+ mock(DatabaseCleaner).start.never
24
+ mock(DatabaseCleaner).clean.never
25
+ topic.local_run(Riot::SilentReporter.new, Riot::Situation.new)
26
+ end
27
+ end
28
+
29
+ context "when the context doesn't uses database_cleaner" do
30
+ setup do
31
+ Riot::Context.new("test context root") { set :skip_database_cleaner, true }
32
+ end
33
+
34
+ should("start and rollback the transaction for the root context") do
35
+ mock(DatabaseCleaner).start.never
36
+ mock(DatabaseCleaner).clean.never
37
+ topic.local_run(Riot::SilentReporter.new, Riot::Situation.new)
38
+ end
39
+ end
40
+ end
@@ -0,0 +1,4 @@
1
+ test:
2
+ adapter: "sqlite3"
3
+ database: <%= Rails.root + "db" + "test.db" %>
4
+
@@ -0,0 +1,43 @@
1
+ ENV['RAILS_ENV'] = 'test'
2
+
3
+ require 'sqlite3'
4
+ require "active_record/railtie"
5
+
6
+ module RiotOnRails
7
+ class Application < Rails::Application
8
+ config.root = File.expand_path(File.join(File.dirname(__FILE__), ".."))
9
+
10
+ config.session_store :cookie_store, {:key => "_riotonrails_session"}
11
+ config.secret_token = "i own you." * 3
12
+ end
13
+ end
14
+
15
+ RiotOnRails::Application.initialize!
16
+
17
+ #require File.join(Rails.root, "config", "routes.rb")
18
+
19
+ # Logging stuff
20
+
21
+ class NilIO
22
+ def write(*args); end
23
+ def close(*args); end
24
+ def puts(*args); end
25
+ def path; nil; end
26
+ def fsync; 0; end
27
+ def to_s; "hello"; end
28
+ def sync; true; end
29
+ def sync=(arg); arg; end
30
+ end
31
+
32
+ def shhh(&block)
33
+ orig_out = $stdout
34
+ $stdout = NilIO.new
35
+ yield
36
+ $stdout = orig_out
37
+ end
38
+
39
+ shhh do
40
+ load(File.join(Rails.root, "db", "schema.rb"))
41
+ end
42
+
43
+ ActiveRecord::Base.logger = Logger.new(NilIO.new)
@@ -0,0 +1,8 @@
1
+ ActiveRecord::Schema.define(:version => 1) do
2
+ create_table :rooms, :force => true do |t|
3
+ t.string :location
4
+ t.string :email
5
+ t.string :contents
6
+ t.string :name
7
+ end
8
+ end
Binary file
@@ -0,0 +1,632 @@
1
+ SQL (0.2ms) select sqlite_version(*)
2
+ SQL (0.2ms) SELECT name
3
+ FROM sqlite_master
4
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
5
+ SQL (1.2ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255)) 
6
+ SQL (0.2ms) SELECT name
7
+ FROM sqlite_master
8
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
9
+ SQL (0.9ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
10
+ SQL (0.1ms) PRAGMA index_list("schema_migrations")
11
+ SQL (1.1ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
12
+ SQL (0.3ms) SELECT name
13
+ FROM sqlite_master
14
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
15
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
16
+ SQL (0.9ms) INSERT INTO "schema_migrations" (version) VALUES ('1')
17
+ SQL (0.2ms) select sqlite_version(*)
18
+ SQL (0.3ms) SELECT name
19
+ FROM sqlite_master
20
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
21
+ SQL (1.0ms) DROP TABLE "rooms"
22
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
23
+ SQL (0.1ms)  SELECT name
24
+ FROM sqlite_master
25
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
26
+ 
27
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
28
+ SQL (0.2ms) select sqlite_version(*)
29
+ SQL (0.3ms) SELECT name
30
+ FROM sqlite_master
31
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
32
+ SQL (1.1ms) DROP TABLE "rooms"
33
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
34
+ SQL (0.1ms)  SELECT name
35
+ FROM sqlite_master
36
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
37
+ 
38
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
39
+ SQL (0.2ms) select sqlite_version(*)
40
+ SQL (0.3ms) SELECT name
41
+ FROM sqlite_master
42
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
43
+ SQL (1.1ms) DROP TABLE "rooms"
44
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
45
+ SQL (0.1ms)  SELECT name
46
+ FROM sqlite_master
47
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
48
+ 
49
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
50
+ SQL (0.2ms) select sqlite_version(*)
51
+ SQL (0.3ms) SELECT name
52
+ FROM sqlite_master
53
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
54
+ SQL (1.1ms) DROP TABLE "rooms"
55
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
56
+ SQL (0.1ms)  SELECT name
57
+ FROM sqlite_master
58
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
59
+ 
60
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
61
+ SQL (0.2ms) select sqlite_version(*)
62
+ SQL (0.3ms) SELECT name
63
+ FROM sqlite_master
64
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
65
+ SQL (1.1ms) DROP TABLE "rooms"
66
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
67
+ SQL (0.1ms)  SELECT name
68
+ FROM sqlite_master
69
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
70
+ 
71
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
72
+ SQL (0.2ms) select sqlite_version(*)
73
+ SQL (0.3ms) SELECT name
74
+ FROM sqlite_master
75
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
76
+ SQL (1.0ms) DROP TABLE "rooms"
77
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
78
+ SQL (0.1ms)  SELECT name
79
+ FROM sqlite_master
80
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
81
+ 
82
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
83
+ SQL (0.2ms) select sqlite_version(*)
84
+ SQL (0.3ms) SELECT name
85
+ FROM sqlite_master
86
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
87
+ SQL (1.1ms) DROP TABLE "rooms"
88
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
89
+ SQL (0.1ms)  SELECT name
90
+ FROM sqlite_master
91
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
92
+ 
93
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
94
+ SQL (0.2ms) select sqlite_version(*)
95
+ SQL (0.3ms) SELECT name
96
+ FROM sqlite_master
97
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
98
+ SQL (1.1ms) DROP TABLE "rooms"
99
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
100
+ SQL (0.1ms)  SELECT name
101
+ FROM sqlite_master
102
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
103
+ 
104
+ SQL (0.2ms) SELECT version FROM "schema_migrations"
105
+ SQL (0.2ms) select sqlite_version(*)
106
+ SQL (0.3ms) SELECT name
107
+ FROM sqlite_master
108
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
109
+ SQL (1.1ms) DROP TABLE "rooms"
110
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
111
+ SQL (0.1ms)  SELECT name
112
+ FROM sqlite_master
113
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
114
+ 
115
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
116
+ SQL (0.2ms) select sqlite_version(*)
117
+ SQL (0.3ms) SELECT name
118
+ FROM sqlite_master
119
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
120
+ SQL (1.0ms) DROP TABLE "rooms"
121
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
122
+ SQL (0.2ms)  SELECT name
123
+ FROM sqlite_master
124
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
125
+ 
126
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
127
+ SQL (0.2ms) select sqlite_version(*)
128
+ SQL (0.3ms) SELECT name
129
+ FROM sqlite_master
130
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
131
+ SQL (3.6ms) DROP TABLE "rooms"
132
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
133
+ SQL (0.1ms)  SELECT name
134
+ FROM sqlite_master
135
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
136
+ 
137
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
138
+ SQL (0.2ms) select sqlite_version(*)
139
+ SQL (0.3ms) SELECT name
140
+ FROM sqlite_master
141
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
142
+ SQL (2.9ms) DROP TABLE "rooms"
143
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
144
+ SQL (0.1ms)  SELECT name
145
+ FROM sqlite_master
146
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
147
+ 
148
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
149
+ SQL (0.2ms) select sqlite_version(*)
150
+ SQL (0.3ms) SELECT name
151
+ FROM sqlite_master
152
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
153
+ SQL (2.8ms) DROP TABLE "rooms"
154
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
155
+ SQL (0.1ms)  SELECT name
156
+ FROM sqlite_master
157
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
158
+ 
159
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
160
+ SQL (0.2ms) select sqlite_version(*)
161
+ SQL (0.3ms) SELECT name
162
+ FROM sqlite_master
163
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
164
+ SQL (3.5ms) DROP TABLE "rooms"
165
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
166
+ SQL (0.2ms)  SELECT name
167
+ FROM sqlite_master
168
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
169
+ 
170
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
171
+ SQL (0.2ms) select sqlite_version(*)
172
+ SQL (0.3ms) SELECT name
173
+ FROM sqlite_master
174
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
175
+ SQL (2.6ms) DROP TABLE "rooms"
176
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
177
+ SQL (0.1ms)  SELECT name
178
+ FROM sqlite_master
179
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
180
+ 
181
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
182
+ SQL (0.2ms) select sqlite_version(*)
183
+ SQL (0.3ms) SELECT name
184
+ FROM sqlite_master
185
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
186
+ SQL (3.6ms) DROP TABLE "rooms"
187
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
188
+ SQL (0.1ms)  SELECT name
189
+ FROM sqlite_master
190
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
191
+ 
192
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
193
+ SQL (0.2ms) select sqlite_version(*)
194
+ SQL (0.3ms) SELECT name
195
+ FROM sqlite_master
196
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
197
+ SQL (3.8ms) DROP TABLE "rooms"
198
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
199
+ SQL (0.1ms)  SELECT name
200
+ FROM sqlite_master
201
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
202
+ 
203
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
204
+ SQL (0.2ms) select sqlite_version(*)
205
+ SQL (0.3ms) SELECT name
206
+ FROM sqlite_master
207
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
208
+ SQL (3.7ms) DROP TABLE "rooms"
209
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
210
+ SQL (0.1ms)  SELECT name
211
+ FROM sqlite_master
212
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
213
+ 
214
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
215
+ SQL (0.2ms) select sqlite_version(*)
216
+ SQL (0.3ms) SELECT name
217
+ FROM sqlite_master
218
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
219
+ SQL (3.7ms) DROP TABLE "rooms"
220
+ SQL (1.1ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
221
+ SQL (0.2ms)  SELECT name
222
+ FROM sqlite_master
223
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
224
+ 
225
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
226
+ SQL (0.2ms) select sqlite_version(*)
227
+ SQL (0.3ms) SELECT name
228
+ FROM sqlite_master
229
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
230
+ SQL (1.1ms) DROP TABLE "rooms"
231
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
232
+ SQL (0.2ms)  SELECT name
233
+ FROM sqlite_master
234
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
235
+ 
236
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
237
+ SQL (0.2ms) select sqlite_version(*)
238
+ SQL (0.3ms) SELECT name
239
+ FROM sqlite_master
240
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
241
+ SQL (3.0ms) DROP TABLE "rooms"
242
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
243
+ SQL (0.1ms)  SELECT name
244
+ FROM sqlite_master
245
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
246
+ 
247
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
248
+ SQL (0.2ms) select sqlite_version(*)
249
+ SQL (0.3ms) SELECT name
250
+ FROM sqlite_master
251
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
252
+ SQL (3.7ms) DROP TABLE "rooms"
253
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
254
+ SQL (0.1ms)  SELECT name
255
+ FROM sqlite_master
256
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
257
+ 
258
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
259
+ SQL (0.2ms) select sqlite_version(*)
260
+ SQL (0.3ms) SELECT name
261
+ FROM sqlite_master
262
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
263
+ SQL (3.7ms) DROP TABLE "rooms"
264
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
265
+ SQL (0.1ms)  SELECT name
266
+ FROM sqlite_master
267
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
268
+ 
269
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
270
+ SQL (0.2ms) select sqlite_version(*)
271
+ SQL (0.3ms) SELECT name
272
+ FROM sqlite_master
273
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
274
+ SQL (2.8ms) DROP TABLE "rooms"
275
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
276
+ SQL (0.1ms)  SELECT name
277
+ FROM sqlite_master
278
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
279
+ 
280
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
281
+ SQL (0.2ms) select sqlite_version(*)
282
+ SQL (0.3ms) SELECT name
283
+ FROM sqlite_master
284
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
285
+ SQL (3.7ms) DROP TABLE "rooms"
286
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
287
+ SQL (0.2ms)  SELECT name
288
+ FROM sqlite_master
289
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
290
+ 
291
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
292
+ SQL (0.2ms) select sqlite_version(*)
293
+ SQL (0.3ms) SELECT name
294
+ FROM sqlite_master
295
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
296
+ SQL (3.7ms) DROP TABLE "rooms"
297
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
298
+ SQL (0.1ms)  SELECT name
299
+ FROM sqlite_master
300
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
301
+ 
302
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
303
+ SQL (0.2ms) select sqlite_version(*)
304
+ SQL (0.3ms) SELECT name
305
+ FROM sqlite_master
306
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
307
+ SQL (4.0ms) DROP TABLE "rooms"
308
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
309
+ SQL (0.1ms)  SELECT name
310
+ FROM sqlite_master
311
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
312
+ 
313
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
314
+ SQL (0.2ms) select sqlite_version(*)
315
+ SQL (0.3ms) SELECT name
316
+ FROM sqlite_master
317
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
318
+ SQL (3.8ms) DROP TABLE "rooms"
319
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
320
+ SQL (0.2ms)  SELECT name
321
+ FROM sqlite_master
322
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
323
+ 
324
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
325
+ SQL (0.2ms) select sqlite_version(*)
326
+ SQL (0.3ms) SELECT name
327
+ FROM sqlite_master
328
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
329
+ SQL (3.7ms) DROP TABLE "rooms"
330
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
331
+ SQL (0.2ms)  SELECT name
332
+ FROM sqlite_master
333
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
334
+ 
335
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
336
+ SQL (0.2ms) select sqlite_version(*)
337
+ SQL (0.3ms) SELECT name
338
+ FROM sqlite_master
339
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
340
+ SQL (2.6ms) DROP TABLE "rooms"
341
+ SQL (1.1ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
342
+ SQL (0.2ms)  SELECT name
343
+ FROM sqlite_master
344
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
345
+ 
346
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
347
+ SQL (0.2ms) select sqlite_version(*)
348
+ SQL (0.3ms) SELECT name
349
+ FROM sqlite_master
350
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
351
+ SQL (2.8ms) DROP TABLE "rooms"
352
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
353
+ SQL (0.2ms)  SELECT name
354
+ FROM sqlite_master
355
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
356
+ 
357
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
358
+ SQL (0.2ms) select sqlite_version(*)
359
+ SQL (0.3ms) SELECT name
360
+ FROM sqlite_master
361
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
362
+ SQL (2.8ms) DROP TABLE "rooms"
363
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
364
+ SQL (0.1ms)  SELECT name
365
+ FROM sqlite_master
366
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
367
+ 
368
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
369
+ SQL (0.2ms) select sqlite_version(*)
370
+ SQL (0.3ms) SELECT name
371
+ FROM sqlite_master
372
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
373
+ SQL (3.8ms) DROP TABLE "rooms"
374
+ SQL (1.1ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
375
+ SQL (0.1ms)  SELECT name
376
+ FROM sqlite_master
377
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
378
+ 
379
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
380
+ SQL (0.2ms) select sqlite_version(*)
381
+ SQL (0.3ms) SELECT name
382
+ FROM sqlite_master
383
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
384
+ SQL (195.2ms) DROP TABLE "rooms"
385
+ SQL (1.2ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
386
+ SQL (0.2ms)  SELECT name
387
+ FROM sqlite_master
388
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
389
+ 
390
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
391
+ SQL (0.2ms) select sqlite_version(*)
392
+ SQL (0.3ms) SELECT name
393
+ FROM sqlite_master
394
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
395
+ SQL (2.9ms) DROP TABLE "rooms"
396
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
397
+ SQL (0.1ms)  SELECT name
398
+ FROM sqlite_master
399
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
400
+ 
401
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
402
+ SQL (0.2ms) select sqlite_version(*)
403
+ SQL (0.3ms) SELECT name
404
+ FROM sqlite_master
405
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
406
+ SQL (2.7ms) DROP TABLE "rooms"
407
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
408
+ SQL (0.1ms)  SELECT name
409
+ FROM sqlite_master
410
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
411
+ 
412
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
413
+ SQL (0.2ms) select sqlite_version(*)
414
+ SQL (0.3ms) SELECT name
415
+ FROM sqlite_master
416
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
417
+ SQL (2.6ms) DROP TABLE "rooms"
418
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
419
+ SQL (0.1ms)  SELECT name
420
+ FROM sqlite_master
421
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
422
+ 
423
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
424
+ SQL (0.2ms) select sqlite_version(*)
425
+ SQL (0.3ms) SELECT name
426
+ FROM sqlite_master
427
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
428
+ SQL (3.7ms) DROP TABLE "rooms"
429
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
430
+ SQL (0.1ms)  SELECT name
431
+ FROM sqlite_master
432
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
433
+ 
434
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
435
+ SQL (0.2ms) select sqlite_version(*)
436
+ SQL (0.3ms) SELECT name
437
+ FROM sqlite_master
438
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
439
+ SQL (3.8ms) DROP TABLE "rooms"
440
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
441
+ SQL (0.1ms)  SELECT name
442
+ FROM sqlite_master
443
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
444
+ 
445
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
446
+ SQL (0.2ms) select sqlite_version(*)
447
+ SQL (0.3ms) SELECT name
448
+ FROM sqlite_master
449
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
450
+ SQL (2.7ms) DROP TABLE "rooms"
451
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
452
+ SQL (0.1ms)  SELECT name
453
+ FROM sqlite_master
454
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
455
+ 
456
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
457
+ SQL (0.2ms) select sqlite_version(*)
458
+ SQL (0.3ms) SELECT name
459
+ FROM sqlite_master
460
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
461
+ SQL (3.6ms) DROP TABLE "rooms"
462
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
463
+ SQL (0.2ms)  SELECT name
464
+ FROM sqlite_master
465
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
466
+ 
467
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
468
+ SQL (0.2ms) select sqlite_version(*)
469
+ SQL (0.3ms) SELECT name
470
+ FROM sqlite_master
471
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
472
+ SQL (3.7ms) DROP TABLE "rooms"
473
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
474
+ SQL (0.1ms)  SELECT name
475
+ FROM sqlite_master
476
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
477
+ 
478
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
479
+ SQL (0.2ms) select sqlite_version(*)
480
+ SQL (0.3ms) SELECT name
481
+ FROM sqlite_master
482
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
483
+ SQL (3.7ms) DROP TABLE "rooms"
484
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
485
+ SQL (0.1ms)  SELECT name
486
+ FROM sqlite_master
487
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
488
+ 
489
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
490
+ SQL (0.2ms) select sqlite_version(*)
491
+ SQL (0.3ms) SELECT name
492
+ FROM sqlite_master
493
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
494
+ SQL (3.8ms) DROP TABLE "rooms"
495
+ SQL (1.2ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
496
+ SQL (0.2ms)  SELECT name
497
+ FROM sqlite_master
498
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
499
+ 
500
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
501
+ SQL (0.2ms) select sqlite_version(*)
502
+ SQL (0.3ms) SELECT name
503
+ FROM sqlite_master
504
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
505
+ SQL (2.8ms) DROP TABLE "rooms"
506
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
507
+ SQL (0.2ms)  SELECT name
508
+ FROM sqlite_master
509
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
510
+ 
511
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
512
+ SQL (0.2ms) select sqlite_version(*)
513
+ SQL (0.3ms) SELECT name
514
+ FROM sqlite_master
515
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
516
+ SQL (2.7ms) DROP TABLE "rooms"
517
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
518
+ SQL (0.1ms)  SELECT name
519
+ FROM sqlite_master
520
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
521
+ 
522
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
523
+ SQL (0.2ms) select sqlite_version(*)
524
+ SQL (0.3ms) SELECT name
525
+ FROM sqlite_master
526
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
527
+ SQL (2.6ms) DROP TABLE "rooms"
528
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
529
+ SQL (0.1ms)  SELECT name
530
+ FROM sqlite_master
531
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
532
+ 
533
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
534
+ SQL (0.2ms) select sqlite_version(*)
535
+ SQL (0.3ms) SELECT name
536
+ FROM sqlite_master
537
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
538
+ SQL (2.6ms) DROP TABLE "rooms"
539
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
540
+ SQL (0.1ms)  SELECT name
541
+ FROM sqlite_master
542
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
543
+ 
544
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
545
+ SQL (0.2ms) select sqlite_version(*)
546
+ SQL (0.3ms) SELECT name
547
+ FROM sqlite_master
548
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
549
+ SQL (3.9ms) DROP TABLE "rooms"
550
+ SQL (1.1ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
551
+ SQL (0.2ms)  SELECT name
552
+ FROM sqlite_master
553
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
554
+ 
555
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
556
+ SQL (0.2ms) select sqlite_version(*)
557
+ SQL (0.3ms) SELECT name
558
+ FROM sqlite_master
559
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
560
+ SQL (1.1ms) DROP TABLE "rooms"
561
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
562
+ SQL (0.2ms)  SELECT name
563
+ FROM sqlite_master
564
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
565
+ 
566
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
567
+ SQL (0.2ms) select sqlite_version(*)
568
+ SQL (0.3ms) SELECT name
569
+ FROM sqlite_master
570
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
571
+ SQL (3.8ms) DROP TABLE "rooms"
572
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
573
+ SQL (0.2ms)  SELECT name
574
+ FROM sqlite_master
575
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
576
+ 
577
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
578
+ SQL (0.2ms) select sqlite_version(*)
579
+ SQL (0.3ms) SELECT name
580
+ FROM sqlite_master
581
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
582
+ SQL (3.8ms) DROP TABLE "rooms"
583
+ SQL (1.1ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
584
+ SQL (0.2ms)  SELECT name
585
+ FROM sqlite_master
586
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
587
+ 
588
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
589
+ SQL (0.2ms) select sqlite_version(*)
590
+ SQL (0.3ms) SELECT name
591
+ FROM sqlite_master
592
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
593
+ SQL (2.6ms) DROP TABLE "rooms"
594
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
595
+ SQL (0.2ms)  SELECT name
596
+ FROM sqlite_master
597
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
598
+ 
599
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
600
+ SQL (0.2ms) select sqlite_version(*)
601
+ SQL (0.3ms) SELECT name
602
+ FROM sqlite_master
603
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
604
+ SQL (3.9ms) DROP TABLE "rooms"
605
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
606
+ SQL (0.2ms)  SELECT name
607
+ FROM sqlite_master
608
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
609
+ 
610
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
611
+ SQL (0.2ms) select sqlite_version(*)
612
+ SQL (0.3ms) SELECT name
613
+ FROM sqlite_master
614
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
615
+ SQL (2.8ms) DROP TABLE "rooms"
616
+ SQL (0.9ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
617
+ SQL (0.1ms)  SELECT name
618
+ FROM sqlite_master
619
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
620
+ 
621
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
622
+ SQL (0.2ms) select sqlite_version(*)
623
+ SQL (0.3ms) SELECT name
624
+ FROM sqlite_master
625
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
626
+ SQL (2.7ms) DROP TABLE "rooms"
627
+ SQL (1.0ms) CREATE TABLE "rooms" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "location" varchar(255), "email" varchar(255), "contents" varchar(255), "name" varchar(255))
628
+ SQL (0.2ms)  SELECT name
629
+ FROM sqlite_master
630
+ WHERE type = 'table' AND NOT name = 'sqlite_sequence'
631
+ 
632
+ SQL (0.1ms) SELECT version FROM "schema_migrations"
@@ -0,0 +1,9 @@
1
+ require "teststrap"
2
+
3
+ context "settung up riot for controller testing" do
4
+ setup { Riot::Situation.new }
5
+
6
+ asserts("defines the app method as the Rails application") { topic.app == Rails.application }
7
+
8
+ asserts("includes the Rack::Test api") { topic.class.ancestors.include? Rack::Test::Methods }
9
+ end
data/test/teststrap.rb ADDED
@@ -0,0 +1,14 @@
1
+ $:.unshift File.join(File.dirname(__FILE__), "..", "lib")
2
+ require "riot"
3
+ require "riot_on_rails"
4
+ require "riot/rr"
5
+
6
+ require(Pathname(__FILE__).dirname + 'rails_root' + 'config' + 'environment')
7
+
8
+ class NullObject
9
+ def method_missing(*args, &block)
10
+ self
11
+ end
12
+
13
+ def nil?; true; end
14
+ end
metadata ADDED
@@ -0,0 +1,224 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: riot_on_rails
3
+ version: !ruby/object:Gem::Version
4
+ hash: 29
5
+ prerelease:
6
+ segments:
7
+ - 0
8
+ - 0
9
+ - 1
10
+ version: 0.0.1
11
+ platform: ruby
12
+ authors:
13
+ - "Lucas H\xC3\xBAngaro"
14
+ autorequire:
15
+ bindir: bin
16
+ cert_chain: []
17
+
18
+ date: 2011-06-01 00:00:00 -03:00
19
+ default_executable:
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
22
+ version_requirements: &id001 !ruby/object:Gem::Requirement
23
+ none: false
24
+ requirements:
25
+ - - ~>
26
+ - !ruby/object:Gem::Version
27
+ hash: 39
28
+ segments:
29
+ - 0
30
+ - 12
31
+ - 4
32
+ version: 0.12.4
33
+ requirement: *id001
34
+ prerelease: false
35
+ type: :runtime
36
+ name: riot
37
+ - !ruby/object:Gem::Dependency
38
+ version_requirements: &id002 !ruby/object:Gem::Requirement
39
+ none: false
40
+ requirements:
41
+ - - ~>
42
+ - !ruby/object:Gem::Version
43
+ hash: 5
44
+ segments:
45
+ - 0
46
+ - 5
47
+ - 7
48
+ version: 0.5.7
49
+ requirement: *id002
50
+ prerelease: false
51
+ type: :runtime
52
+ name: rack-test
53
+ - !ruby/object:Gem::Dependency
54
+ version_requirements: &id003 !ruby/object:Gem::Requirement
55
+ none: false
56
+ requirements:
57
+ - - ~>
58
+ - !ruby/object:Gem::Version
59
+ hash: 9
60
+ segments:
61
+ - 0
62
+ - 6
63
+ - 7
64
+ version: 0.6.7
65
+ requirement: *id003
66
+ prerelease: false
67
+ type: :runtime
68
+ name: database_cleaner
69
+ - !ruby/object:Gem::Dependency
70
+ version_requirements: &id004 !ruby/object:Gem::Requirement
71
+ none: false
72
+ requirements:
73
+ - - ~>
74
+ - !ruby/object:Gem::Version
75
+ hash: 49
76
+ segments:
77
+ - 0
78
+ - 8
79
+ - 7
80
+ version: 0.8.7
81
+ requirement: *id004
82
+ prerelease: false
83
+ type: :development
84
+ name: rake
85
+ - !ruby/object:Gem::Dependency
86
+ version_requirements: &id005 !ruby/object:Gem::Requirement
87
+ none: false
88
+ requirements:
89
+ - - ~>
90
+ - !ruby/object:Gem::Version
91
+ hash: 19
92
+ segments:
93
+ - 1
94
+ - 0
95
+ - 2
96
+ version: 1.0.2
97
+ requirement: *id005
98
+ prerelease: false
99
+ type: :development
100
+ name: rr
101
+ - !ruby/object:Gem::Dependency
102
+ version_requirements: &id006 !ruby/object:Gem::Requirement
103
+ none: false
104
+ requirements:
105
+ - - ">="
106
+ - !ruby/object:Gem::Version
107
+ hash: 7
108
+ segments:
109
+ - 3
110
+ - 0
111
+ - 0
112
+ version: 3.0.0
113
+ requirement: *id006
114
+ prerelease: false
115
+ type: :development
116
+ name: activerecord
117
+ - !ruby/object:Gem::Dependency
118
+ version_requirements: &id007 !ruby/object:Gem::Requirement
119
+ none: false
120
+ requirements:
121
+ - - ~>
122
+ - !ruby/object:Gem::Version
123
+ hash: 29
124
+ segments:
125
+ - 1
126
+ - 3
127
+ - 3
128
+ version: 1.3.3
129
+ requirement: *id007
130
+ prerelease: false
131
+ type: :development
132
+ name: sqlite3
133
+ - !ruby/object:Gem::Dependency
134
+ version_requirements: &id008 !ruby/object:Gem::Requirement
135
+ none: false
136
+ requirements:
137
+ - - ">="
138
+ - !ruby/object:Gem::Version
139
+ hash: 7
140
+ segments:
141
+ - 3
142
+ - 0
143
+ - 0
144
+ version: 3.0.0
145
+ requirement: *id008
146
+ prerelease: false
147
+ type: :development
148
+ name: rails
149
+ description: |-
150
+ A set of utilities to make developing Rails apps with Riot easier.
151
+ No extra macros or helpers provided, just the bare basics.
152
+ email:
153
+ - lucashungaro@gmail.com
154
+ executables: []
155
+
156
+ extensions: []
157
+
158
+ extra_rdoc_files: []
159
+
160
+ files:
161
+ - .gitignore
162
+ - Gemfile
163
+ - MIT-LICENSE
164
+ - README.textile
165
+ - Rakefile
166
+ - lib/riot_on_rails.rb
167
+ - lib/riot_on_rails/configuration.rb
168
+ - lib/riot_on_rails/database_cleaner_middleware.rb
169
+ - lib/riot_on_rails/setup_controller_tests.rb
170
+ - lib/riot_on_rails/version.rb
171
+ - riot_on_rails.gemspec
172
+ - test/database_cleaner_middleware_test.rb
173
+ - test/rails_root/config/database.yml
174
+ - test/rails_root/config/environment.rb
175
+ - test/rails_root/db/schema.rb
176
+ - test/rails_root/db/test.db
177
+ - test/rails_root/log/test.log
178
+ - test/setup_controller_tests_test.rb
179
+ - test/teststrap.rb
180
+ has_rdoc: true
181
+ homepage: https://github.com/lucashungaro/riot_on_rails
182
+ licenses: []
183
+
184
+ post_install_message:
185
+ rdoc_options: []
186
+
187
+ require_paths:
188
+ - lib
189
+ required_ruby_version: !ruby/object:Gem::Requirement
190
+ none: false
191
+ requirements:
192
+ - - ">="
193
+ - !ruby/object:Gem::Version
194
+ hash: 3
195
+ segments:
196
+ - 0
197
+ version: "0"
198
+ required_rubygems_version: !ruby/object:Gem::Requirement
199
+ none: false
200
+ requirements:
201
+ - - ">="
202
+ - !ruby/object:Gem::Version
203
+ hash: 23
204
+ segments:
205
+ - 1
206
+ - 3
207
+ - 6
208
+ version: 1.3.6
209
+ requirements: []
210
+
211
+ rubyforge_project: riot_on_rails
212
+ rubygems_version: 1.6.2
213
+ signing_key:
214
+ specification_version: 3
215
+ summary: Hooks the Riot testing framework into Ruby on Rails
216
+ test_files:
217
+ - test/database_cleaner_middleware_test.rb
218
+ - test/rails_root/config/database.yml
219
+ - test/rails_root/config/environment.rb
220
+ - test/rails_root/db/schema.rb
221
+ - test/rails_root/db/test.db
222
+ - test/rails_root/log/test.log
223
+ - test/setup_controller_tests_test.rb
224
+ - test/teststrap.rb