ridgepole 0.7.8 → 0.8.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (168) hide show
  1. checksums.yaml +4 -4
  2. data/.rspec +1 -1
  3. data/.rubocop.yml +1 -3
  4. data/.travis.yml +11 -3
  5. data/Appraisals +4 -2
  6. data/Gemfile +0 -2
  7. data/README.md +3 -4
  8. data/Rakefile +0 -2
  9. data/bin/ridgepole +2 -4
  10. data/gemfiles/activerecord_6.0.gemfile +7 -0
  11. data/lib/ridgepole.rb +0 -2
  12. data/lib/ridgepole/cli/config.rb +0 -2
  13. data/lib/ridgepole/client.rb +0 -2
  14. data/lib/ridgepole/connection_adapters.rb +0 -2
  15. data/lib/ridgepole/default_limit.rb +0 -2
  16. data/lib/ridgepole/delta.rb +1 -3
  17. data/lib/ridgepole/diff.rb +2 -4
  18. data/lib/ridgepole/dsl_parser.rb +0 -2
  19. data/lib/ridgepole/dsl_parser/context.rb +3 -5
  20. data/lib/ridgepole/dsl_parser/table_definition.rb +0 -2
  21. data/lib/ridgepole/dumper.rb +0 -2
  22. data/lib/ridgepole/execute_expander.rb +2 -4
  23. data/lib/ridgepole/ext/abstract_adapter/disable_table_options.rb +0 -2
  24. data/lib/ridgepole/ext/abstract_mysql_adapter/dump_auto_increment.rb +0 -2
  25. data/lib/ridgepole/ext/abstract_mysql_adapter/use_alter_index.rb +0 -2
  26. data/lib/ridgepole/ext/pp_sort_hash.rb +0 -2
  27. data/lib/ridgepole/ext/schema_dumper.rb +0 -2
  28. data/lib/ridgepole/external_sql_executer.rb +0 -2
  29. data/lib/ridgepole/logger.rb +0 -2
  30. data/lib/ridgepole/migration_ext.rb +0 -2
  31. data/lib/ridgepole/schema_dumper_ext.rb +0 -2
  32. data/lib/ridgepole/schema_statements_ext.rb +0 -2
  33. data/lib/ridgepole/version.rb +1 -3
  34. data/ridgepole.gemspec +0 -2
  35. data/spec/cli_helper.rb +0 -2
  36. data/spec/erb_helper.rb +0 -2
  37. data/spec/hide_pending_formatter.rb +0 -2
  38. data/spec/mysql/_migrate/migrate_change_table_option_spec.rb +3 -5
  39. data/spec/mysql/bigint_pk/bigint_pk_spec.rb +0 -2
  40. data/spec/mysql/bigint_pk/int_pk_spec.rb +0 -2
  41. data/spec/mysql/cli/config_spec.rb +0 -2
  42. data/spec/mysql/cli/ridgepole_spec.rb +0 -2
  43. data/spec/mysql/collation/collation_spec.rb +0 -2
  44. data/spec/mysql/comment/comment_spec.rb +0 -2
  45. data/spec/mysql/default_lambda/default_lambda_spec.rb +0 -2
  46. data/spec/mysql/diff/diff2_spec.rb +0 -2
  47. data/spec/mysql/diff/diff_spec.rb +0 -2
  48. data/spec/mysql/dump/dump_class_method_spec.rb +0 -2
  49. data/spec/mysql/dump/dump_some_tables_spec.rb +0 -2
  50. data/spec/mysql/dump/dump_spec.rb +0 -2
  51. data/spec/mysql/dump/dump_unknown_column_type_spec.rb +0 -2
  52. data/spec/mysql/dump/dump_without_table_options_spec.rb +0 -2
  53. data/spec/mysql/fk/migrate_change_fk2_spec.rb +0 -2
  54. data/spec/mysql/fk/migrate_change_fk_spec.rb +0 -2
  55. data/spec/mysql/fk/migrate_create_fk_spec.rb +0 -2
  56. data/spec/mysql/fk/migrate_drop_fk_spec.rb +0 -2
  57. data/spec/mysql/fk/migrate_ignore_fk_spec.rb +0 -2
  58. data/spec/mysql/migrate/check_orphan_index_spec.rb +0 -2
  59. data/spec/mysql/migrate/migrate_add_column2_spec.rb +0 -2
  60. data/spec/mysql/migrate/migrate_add_column_order_spec.rb +0 -2
  61. data/spec/mysql/migrate/migrate_add_column_spec.rb +0 -2
  62. data/spec/mysql/migrate/migrate_add_column_with_alter_extra_spec.rb +0 -2
  63. data/spec/mysql/migrate/migrate_add_column_with_script_spec.rb +0 -2
  64. data/spec/mysql/migrate/migrate_change_column2_spec.rb +0 -2
  65. data/spec/mysql/migrate/migrate_change_column3_spec.rb +0 -2
  66. data/spec/mysql/migrate/migrate_change_column4_spec.rb +0 -2
  67. data/spec/mysql/migrate/migrate_change_column5_spec.rb +0 -2
  68. data/spec/mysql/migrate/migrate_change_column6_spec.rb +0 -2
  69. data/spec/mysql/migrate/migrate_change_column7_spec.rb +0 -2
  70. data/spec/mysql/migrate/migrate_change_column8_spec.rb +0 -2
  71. data/spec/mysql/migrate/migrate_change_column_default_spec.rb +0 -2
  72. data/spec/mysql/migrate/migrate_change_column_float_spec.rb +0 -2
  73. data/spec/mysql/migrate/migrate_change_column_spec.rb +0 -2
  74. data/spec/mysql/migrate/migrate_change_index2_spec.rb +0 -2
  75. data/spec/mysql/migrate/migrate_change_index3_spec.rb +0 -2
  76. data/spec/mysql/migrate/migrate_change_index4_spec.rb +0 -2
  77. data/spec/mysql/migrate/migrate_change_index5_spec.rb +0 -2
  78. data/spec/mysql/migrate/migrate_change_index6_spec.rb +0 -2
  79. data/spec/mysql/migrate/migrate_change_index7_spec.rb +0 -2
  80. data/spec/mysql/migrate/migrate_change_index8_spec.rb +0 -2
  81. data/spec/mysql/migrate/migrate_change_index_spec.rb +0 -2
  82. data/spec/mysql/migrate/migrate_change_table_comment_spec.rb +0 -2
  83. data/spec/mysql/migrate/migrate_change_table_option_spec.rb +0 -2
  84. data/spec/mysql/migrate/migrate_check_relation_column_type_spec.rb +0 -2
  85. data/spec/mysql/migrate/migrate_create_index2_spec.rb +0 -2
  86. data/spec/mysql/migrate/migrate_create_index_spec.rb +0 -2
  87. data/spec/mysql/migrate/migrate_create_table_spec.rb +0 -2
  88. data/spec/mysql/migrate/migrate_create_table_with_ignore_spec.rb +0 -2
  89. data/spec/mysql/migrate/migrate_create_table_with_index_spec.rb +0 -2
  90. data/spec/mysql/migrate/migrate_create_table_with_options_spec.rb +0 -2
  91. data/spec/mysql/migrate/migrate_create_table_with_script_spec.rb +0 -2
  92. data/spec/mysql/migrate/migrate_drop_column_and_index2_spec.rb +0 -2
  93. data/spec/mysql/migrate/migrate_drop_column_and_index_spec.rb +0 -2
  94. data/spec/mysql/migrate/migrate_drop_column_and_unique_index_spec.rb +0 -2
  95. data/spec/mysql/migrate/migrate_drop_column_spec.rb +0 -2
  96. data/spec/mysql/migrate/migrate_drop_index_spec.rb +0 -2
  97. data/spec/mysql/migrate/migrate_drop_table_spec.rb +0 -2
  98. data/spec/mysql/migrate/migrate_duplicate_index_spec.rb +0 -2
  99. data/spec/mysql/migrate/migrate_duplicate_table_spec.rb +0 -2
  100. data/spec/mysql/migrate/migrate_empty_spec.rb +0 -2
  101. data/spec/mysql/migrate/migrate_execute_spec.rb +0 -2
  102. data/spec/mysql/migrate/migrate_ignore_column_spec.rb +0 -2
  103. data/spec/mysql/migrate/migrate_ignore_index_spec.rb +0 -2
  104. data/spec/mysql/migrate/migrate_log_file_spec.rb +0 -2
  105. data/spec/mysql/migrate/migrate_merge_mode_spec.rb +0 -2
  106. data/spec/mysql/migrate/migrate_noop_spec.rb +0 -2
  107. data/spec/mysql/migrate/migrate_primary_key_spec.rb +0 -2
  108. data/spec/mysql/migrate/migrate_rename_column_spec.rb +0 -2
  109. data/spec/mysql/migrate/migrate_rename_table_spec.rb +0 -2
  110. data/spec/mysql/migrate/migrate_same_default_null_spec.rb +0 -2
  111. data/spec/mysql/migrate/migrate_same_spec.rb +0 -2
  112. data/spec/mysql/migrate/migrate_script_error_spec.rb +0 -2
  113. data/spec/mysql/migrate/migrate_skip_column_comment_change_spec.rb +0 -2
  114. data/spec/mysql/migrate/migrate_skip_drop_table_spec.rb +0 -2
  115. data/spec/mysql/migrate/migrate_skip_rename_column_spec.rb +0 -2
  116. data/spec/mysql/migrate/migrate_skip_rename_table_spec.rb +0 -2
  117. data/spec/mysql/migrate/migrate_with_ignore_tables_spec.rb +0 -2
  118. data/spec/mysql/migrate/migrate_with_pre_post_query_spec.rb +0 -2
  119. data/spec/mysql/migrate/migrate_with_tables_spec.rb +0 -2
  120. data/spec/mysql/migrate/migrate_with_verbose_log_spec.rb +0 -2
  121. data/spec/mysql/migrate_/migrate_create_index_with_alter_spec.rb +0 -2
  122. data/spec/mysql/migrate_/migrate_drop_index_with_alter_spec.rb +0 -2
  123. data/spec/mysql/text_blob_types/text_blob_types_spec.rb +50 -10
  124. data/spec/mysql/~default_name_fk/migrate_change_fk_spec.rb +0 -2
  125. data/spec/mysql/~default_name_fk/migrate_create_fk_spec.rb +0 -2
  126. data/spec/mysql/~default_name_fk/migrate_drop_fk_spec.rb +0 -2
  127. data/spec/mysql/~dump_auto_increment/migrate_create_table_with_index_spec.rb +0 -2
  128. data/spec/mysql57/json/add_json_column_spec.rb +0 -2
  129. data/spec/mysql57/json/change_json_column_spec.rb +0 -2
  130. data/spec/mysql57/json/drop_json_column_spec.rb +0 -2
  131. data/spec/mysql57/virtual/add_virtual_column_spec.rb +0 -2
  132. data/spec/mysql57/virtual/change_virtual_column_spec.rb +0 -2
  133. data/spec/mysql57/virtual/drop_virtual_column_spec.rb +0 -2
  134. data/spec/postgresql/diff/diff_spec.rb +0 -2
  135. data/spec/postgresql/dump/dump_spec.rb +0 -2
  136. data/spec/postgresql/fk/migrate_change_fk_spec.rb +0 -2
  137. data/spec/postgresql/fk/migrate_create_fk_spec.rb +0 -2
  138. data/spec/postgresql/fk/migrate_drop_fk_spec.rb +0 -2
  139. data/spec/postgresql/migrate/migrate_add_column_spec.rb +0 -2
  140. data/spec/postgresql/migrate/migrate_add_expression_index_spec.rb +0 -2
  141. data/spec/postgresql/migrate/migrate_bigint_spec.rb +0 -2
  142. data/spec/postgresql/migrate/migrate_change_column_default_spec.rb +0 -2
  143. data/spec/postgresql/migrate/migrate_change_column_spec.rb +0 -2
  144. data/spec/postgresql/migrate/migrate_change_index_spec.rb +0 -2
  145. data/spec/postgresql/migrate/migrate_check_relation_column_type_spec.rb +0 -2
  146. data/spec/postgresql/migrate/migrate_create_table_spec.rb +0 -2
  147. data/spec/postgresql/migrate/migrate_create_table_with_default_proc_spec.rb +0 -2
  148. data/spec/postgresql/migrate/migrate_drop_column_spec.rb +0 -2
  149. data/spec/postgresql/migrate/migrate_drop_column_with_index_spec.rb +0 -2
  150. data/spec/postgresql/migrate/migrate_drop_expression_index_spec.rb +0 -2
  151. data/spec/postgresql/migrate/migrate_drop_index_spec.rb +0 -2
  152. data/spec/postgresql/migrate/migrate_drop_table_spec.rb +0 -2
  153. data/spec/postgresql/migrate/migrate_ext_cols_spec.rb +0 -2
  154. data/spec/postgresql/migrate/migrate_primary_key2_spec.rb +0 -2
  155. data/spec/postgresql/migrate/migrate_primary_key_spec.rb +0 -2
  156. data/spec/postgresql/migrate/migrate_references_spec.rb +0 -2
  157. data/spec/postgresql/migrate/migrate_rename_column_spec.rb +0 -2
  158. data/spec/postgresql/migrate/migrate_rename_table_spec.rb +0 -2
  159. data/spec/postgresql/migrate/migrate_same_spec.rb +0 -2
  160. data/spec/postgresql/~default_name_fk/migrate_change_fk_spec.rb +0 -2
  161. data/spec/postgresql/~default_name_fk/migrate_create_fk_spec.rb +0 -2
  162. data/spec/postgresql/~default_name_fk/migrate_drop_fk_spec.rb +0 -2
  163. data/spec/processing_for_travis.rb +0 -2
  164. data/spec/spec_condition.rb +0 -2
  165. data/spec/spec_const.rb +7 -9
  166. data/spec/spec_helper.rb +0 -2
  167. metadata +6 -7
  168. data/spec/mysql/fk/migrate_fk_with_column_spec.rb +0 -163
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create table' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when marge table' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when no operation' do
5
3
  let(:actual_dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  let(:actual_dsl) do
5
3
  erbh(<<-ERB)
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when rename column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when rename table' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when database and definition are same (default null / nothing -> null:true)' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when database and definition are same' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when there is an error in the script' do
5
3
  let(:actual_dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change column ignore comment' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when skil drop table' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when rename column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when rename table' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when with ignore tables option (same)' do
5
3
  let(:current_schema) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'migrate with pre/post query' do
5
3
  let(:actual_dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when with tables option (same)' do
5
3
  let(:current_schema) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'with verbose log' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create index' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop index' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client (with new text/blob types)' do
4
2
  context 'when use new types' do
5
3
  subject { client }
@@ -24,15 +22,15 @@ describe 'Ridgepole::Client (with new text/blob types)' do
24
22
  expect(delta.differ?).to be_truthy
25
23
  delta.migrate
26
24
 
27
- expect(subject.dump).to match_fuzzy erbh(<<-ERB)
25
+ expect(subject.dump).to match_ruby erbh(<<-ERB)
28
26
  create_table "foos", id: :integer, unsigned: true, force: :cascade do |t|
29
27
  t.binary "blob", <%= i cond(5.0, limit: 65535) %>
30
- t.blob "tiny_blob", limit: 255
31
- t.binary "medium_blob", limit: 16777215
32
- t.binary "long_blob", limit: 4294967295
33
- t.text "tiny_text", limit: 255
34
- t.text "medium_text", limit: 16777215
35
- t.text "long_text", limit: 4294967295
28
+ t.<%= cond('< 6.0.0.beta2', :blob, :binary) %> "tiny_blob", <%= i cond('< 6.0.0.beta2', {limit: 255}, {size: :tiny}) %>
29
+ t.binary "medium_blob", <%= i cond('< 6.0.0.beta2', {limit: 16777215}, {size: :medium}) %>
30
+ t.binary "long_blob", <%= i cond('< 6.0.0.beta2', {limit: 4294967295}, {size: :long}) %>
31
+ t.text "tiny_text", <%= i cond('< 6.0.0.beta2', {limit: 255}, {size: :tiny}) %>
32
+ t.text "medium_text", <%= i cond('< 6.0.0.beta2', {limit: 16777215}, {size: :medium}) %>
33
+ t.text "long_text", <%= i cond('< 6.0.0.beta2', {limit: 4294967295}, {size: :long}) %>
36
34
  t.decimal "unsigned_decimal", precision: 10, unsigned: true
37
35
  t.float "unsigned_float", <%= i cond('< 5.2.0.beta2', limit: 24) %>, unsigned: true
38
36
  t.bigint "unsigned_bigint", unsigned: true
@@ -42,7 +40,7 @@ describe 'Ridgepole::Client (with new text/blob types)' do
42
40
  end
43
41
  end
44
42
 
45
- context 'when compare new types' do
43
+ context 'when compare new types', condition: '< 6.0.0.beta2' do
46
44
  subject { client }
47
45
 
48
46
  before do
@@ -83,4 +81,46 @@ describe 'Ridgepole::Client (with new text/blob types)' do
83
81
  expect(delta.differ?).to be_falsey
84
82
  end
85
83
  end
84
+
85
+ context 'when compare new types', condition: '>= 6.0.0.beta2' do
86
+ subject { client }
87
+
88
+ before do
89
+ subject.diff(<<-RUBY).migrate
90
+ create_table "foos", force: :cascade do |t|
91
+ t.binary "blob"
92
+ t.binary "tiny_blob", size: :tiny
93
+ t.binary "medium_blob", size: :medium
94
+ t.binary "long_blob", size: :long
95
+ t.text "tiny_text", size: :tiny
96
+ t.text "medium_text", size: :medium
97
+ t.text "long_text", size: :long
98
+ t.decimal "unsigned_decimal", precision: 10, unsigned: true
99
+ t.float "unsigned_float", unsigned: true
100
+ t.bigint "unsigned_bigint", unsigned: true
101
+ t.integer "unsigned_integer", unsigned: true
102
+ end
103
+ RUBY
104
+ end
105
+
106
+ it do
107
+ delta = subject.diff(<<-RUBY)
108
+ create_table "foos", force: :cascade do |t|
109
+ t.binary "blob"
110
+ t.binary "tiny_blob", size: :tiny
111
+ t.binary "medium_blob", size: :medium
112
+ t.binary "long_blob", size: :long
113
+ t.text "tiny_text", size: :tiny
114
+ t.text "medium_text", size: :medium
115
+ t.text "long_text", size: :long
116
+ t.decimal "unsigned_decimal", precision: 10, unsigned: true
117
+ t.float "unsigned_float", unsigned: true
118
+ t.bigint "unsigned_bigint", unsigned: true
119
+ t.integer "unsigned_integer", unsigned: true
120
+ end
121
+ RUBY
122
+
123
+ expect(delta.differ?).to be_falsey
124
+ end
125
+ end
86
126
  end
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate (with index)', condition: '>= 5.1.0' do
4
2
  context 'when create table with auto increment column' do
5
3
  let(:actual_dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when add virtual column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change virtual column / not null -> null' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when add virtual column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate', condition: '>= 5.1.0' do
4
2
  context 'when add virtual column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate', condition: '>= 5.1.0' do
4
2
  context 'when change virtual column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate', condition: '>= 5.1.0' do
4
2
  context 'when drop virtual column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client.diff' do
4
2
  before do
5
3
  allow(Ridgepole::Diff).to receive(:postgresql?).and_return(true)
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#dump' do
4
2
  context 'when there is a tables' do
5
3
  before { restore_tables }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop fk' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when add column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  subject { client }
5
3
 
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when add bigint column' do
5
3
  let(:actual_dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when change index' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate', condition: '>= 5.1.0' do
4
2
  context 'with warning' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create table' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when create table with default proc' do
5
3
  let(:dsl) { '' }
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop column' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop column and index' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  subject { client }
5
3
 
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop index' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when drop table' do
5
3
  let(:dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate' do
4
2
  context 'when add column (ext cols)' do
5
3
  let(:actual_dsl) do
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  describe 'Ridgepole::Client#diff -> migrate', condition: '>= 5.1.0' do
4
2
  let(:actual_dsl) do
5
3
  erbh(<<-ERB)