ardb 0.25.0 → 0.26.0
Sign up to get free protection for your applications and to get access to all the features.
data/lib/ardb/version.rb
CHANGED
@@ -31,16 +31,40 @@ class Ardb::Runner::MigrateCommand
|
|
31
31
|
|
32
32
|
end
|
33
33
|
|
34
|
-
class
|
34
|
+
class RunSetupTests < InitTests
|
35
35
|
desc "and run"
|
36
|
+
|
37
|
+
end
|
38
|
+
|
39
|
+
class RunTests < RunSetupTests
|
36
40
|
setup do
|
37
41
|
@command.run
|
38
42
|
end
|
39
43
|
|
40
44
|
should "initialize Ardb, migrate the db and dump schema via the adapter" do
|
41
|
-
|
42
|
-
|
43
|
-
|
45
|
+
assert_true @ardb_init_called
|
46
|
+
assert_true @adapter_spy.migrate_db_called?
|
47
|
+
assert_true @adapter_spy.dump_schema_called?
|
48
|
+
end
|
49
|
+
|
50
|
+
end
|
51
|
+
|
52
|
+
class RunWithNoSchemaEnvVarTests < RunSetupTests
|
53
|
+
desc "with no schema dump env var set"
|
54
|
+
setup do
|
55
|
+
@current_no_schema = ENV['ARDB_MIGRATE_NO_SCHEMA']
|
56
|
+
ENV['ARDB_MIGRATE_NO_SCHEMA'] = 'yes'
|
57
|
+
|
58
|
+
@command.run
|
59
|
+
end
|
60
|
+
teardown do
|
61
|
+
ENV['ARDB_MIGRATE_NO_SCHEMA'] = @current_no_schema
|
62
|
+
end
|
63
|
+
|
64
|
+
should "initialize Ardb and migrate the db but not dump schema" do
|
65
|
+
assert_true @ardb_init_called
|
66
|
+
assert_true @adapter_spy.migrate_db_called?
|
67
|
+
assert_false @adapter_spy.dump_schema_called?
|
44
68
|
end
|
45
69
|
|
46
70
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ardb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 119
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
|
-
-
|
8
|
+
- 26
|
9
9
|
- 0
|
10
|
-
version: 0.
|
10
|
+
version: 0.26.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Kelly Redding
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2015-12-
|
19
|
+
date: 2015-12-10 00:00:00 Z
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
22
|
requirement: &id001 !ruby/object:Gem::Requirement
|
@@ -196,7 +196,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
196
196
|
requirements: []
|
197
197
|
|
198
198
|
rubyforge_project:
|
199
|
-
rubygems_version: 1.8.
|
199
|
+
rubygems_version: 1.8.25
|
200
200
|
signing_key:
|
201
201
|
specification_version: 3
|
202
202
|
summary: Activerecord database tools.
|