dbee-active_record 1.0.0.pre.alpha

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +7 -0
  2. data/.editorconfig +8 -0
  3. data/.gitignore +7 -0
  4. data/.rubocop.yml +27 -0
  5. data/.ruby-version +1 -0
  6. data/.travis.yml +30 -0
  7. data/CHANGELOG.md +7 -0
  8. data/CODE_OF_CONDUCT.md +74 -0
  9. data/Gemfile +5 -0
  10. data/Guardfile +16 -0
  11. data/LICENSE +7 -0
  12. data/README.md +75 -0
  13. data/Rakefile +15 -0
  14. data/bin/console +18 -0
  15. data/dbee-active_record.gemspec +36 -0
  16. data/lib/dbee/providers/active_record_provider/expression_builder/constraint_maker.rb +50 -0
  17. data/lib/dbee/providers/active_record_provider/expression_builder/order_maker.rb +23 -0
  18. data/lib/dbee/providers/active_record_provider/expression_builder/select_maker.rb +31 -0
  19. data/lib/dbee/providers/active_record_provider/expression_builder/where_maker.rb +54 -0
  20. data/lib/dbee/providers/active_record_provider/expression_builder.rb +169 -0
  21. data/lib/dbee/providers/active_record_provider/obfuscated_alias_maker.rb +40 -0
  22. data/lib/dbee/providers/active_record_provider/safe_alias_maker.rb +21 -0
  23. data/lib/dbee/providers/active_record_provider/version.rb +16 -0
  24. data/lib/dbee/providers/active_record_provider.rb +51 -0
  25. data/spec/config/database.yaml.ci +9 -0
  26. data/spec/db_helper.rb +56 -0
  27. data/spec/dbee/providers/active_record_provider_spec.rb +79 -0
  28. data/spec/fixtures/active_record_snapshots/five_table_query.yaml +77 -0
  29. data/spec/fixtures/active_record_snapshots/multiple_same_table_query_with_static_constraints.yaml +104 -0
  30. data/spec/fixtures/active_record_snapshots/one_table_query.yaml +26 -0
  31. data/spec/fixtures/active_record_snapshots/one_table_query_with_ascending_sort.yaml +31 -0
  32. data/spec/fixtures/active_record_snapshots/one_table_query_with_descending_sort.yaml +32 -0
  33. data/spec/fixtures/active_record_snapshots/one_table_query_with_filters.yaml +170 -0
  34. data/spec/fixtures/active_record_snapshots/one_table_query_with_limit.yaml +30 -0
  35. data/spec/fixtures/active_record_snapshots/one_table_query_with_multiple_sorts.yaml +33 -0
  36. data/spec/fixtures/active_record_snapshots/two_table_query.yaml +44 -0
  37. data/spec/fixtures/models.yaml +66 -0
  38. data/spec/spec_helper.rb +52 -0
  39. metadata +256 -0
@@ -0,0 +1,170 @@
1
+ model_name: Theaters, Members, and Movies
2
+ query:
3
+ fields:
4
+ - key_path: id
5
+ display: 'ID #'
6
+ - key_path: name
7
+ filters:
8
+ - type: equals
9
+ key_path: name
10
+ value:
11
+ - AMC
12
+ - Regal
13
+ - type: starts_with
14
+ key_path: name
15
+ value: A
16
+ - type: contains
17
+ key_path: name
18
+ value: m
19
+ - type: equals
20
+ key_path: active
21
+ value: 'false' # notice how the value is a string, but the data model should be setup to be a boolean
22
+ - type: equals
23
+ key_path: active
24
+ value:
25
+ - false
26
+ - true
27
+ - null
28
+ - 'y'
29
+ - 'n'
30
+ - ''
31
+ - type: equals
32
+ key_path: inspected
33
+ value:
34
+ - false
35
+ - true
36
+ - null
37
+ - 'y'
38
+ - 'n'
39
+ - ''
40
+ - type: less_than_or_equal_to
41
+ value: '2019-03-04'
42
+ key_path: created_at
43
+ - type: less_than
44
+ value: '2018-03-04'
45
+ key_path: created_at
46
+ - type: greater_than_or_equal_to
47
+ value: '2001-03-04'
48
+ key_path: created_at
49
+ - type: greater_than
50
+ value: '2002-03-04'
51
+ key_path: created_at
52
+ - type: not_equals
53
+ value:
54
+ - 'Netflix'
55
+ - 'Hulu'
56
+ key_path: name
57
+ - type: not_contain
58
+ value:
59
+ - 'tfli'
60
+ - 'ul'
61
+ key_path: name
62
+ - type: not_start_with
63
+ value:
64
+ - 'netf'
65
+ - 'hu'
66
+ key_path: name
67
+ sqlite_readable: |+
68
+ SELECT
69
+ "theaters"."id" AS 'ID #',
70
+ "theaters"."name" AS 'name'
71
+ FROM "theaters" "theaters"
72
+ WHERE
73
+ ("theaters"."name" = 'AMC' OR "theaters"."name" = 'Regal') AND
74
+ "theaters"."name" LIKE 'A%' AND
75
+ "theaters"."name" LIKE '%m%' AND
76
+ "theaters"."active" = 'f' AND
77
+ ((((("theaters"."active" = 'f' OR "theaters"."active" = 't') OR
78
+ "theaters"."active" = 'f') OR "theaters"."active" = 't') OR
79
+ "theaters"."active" = 'f') OR
80
+ "theaters"."active" = 'f') AND
81
+ ((((("theaters"."inspected" = 'f' OR "theaters"."inspected" = 't') OR
82
+ "theaters"."inspected" IS NULL) OR
83
+ "theaters"."inspected" = 't') OR
84
+ "theaters"."inspected" = 'f') OR
85
+ "theaters"."inspected" IS NULL) AND
86
+ "theaters"."created_at" <= '2019-03-04' AND
87
+ "theaters"."created_at" < '2018-03-04' AND
88
+ "theaters"."created_at" >= '2001-03-04' AND
89
+ "theaters"."created_at" > '2002-03-04' AND
90
+ ("theaters"."name" != 'Netflix' OR "theaters"."name" != 'Hulu') AND
91
+ ("theaters"."name" NOT LIKE '%tfli%' OR "theaters"."name" NOT LIKE '%ul%') AND
92
+ ("theaters"."name" NOT LIKE 'netf%' OR "theaters"."name" NOT LIKE 'hu%')
93
+ sqlite_not_readable: |+
94
+ SELECT
95
+ "t0"."id" AS 'c0',
96
+ "t0"."name" AS 'c1'
97
+ FROM "theaters" "t0"
98
+ WHERE
99
+ ("t0"."name" = 'AMC' OR "t0"."name" = 'Regal') AND
100
+ "t0"."name" LIKE 'A%' AND
101
+ "t0"."name" LIKE '%m%' AND
102
+ "t0"."active" = 'f' AND
103
+ ((((("t0"."active" = 'f' OR "t0"."active" = 't') OR
104
+ "t0"."active" = 'f') OR "t0"."active" = 't') OR
105
+ "t0"."active" = 'f') OR
106
+ "t0"."active" = 'f') AND
107
+ ((((("t0"."inspected" = 'f' OR "t0"."inspected" = 't') OR
108
+ "t0"."inspected" IS NULL) OR
109
+ "t0"."inspected" = 't') OR
110
+ "t0"."inspected" = 'f') OR
111
+ "t0"."inspected" IS NULL) AND
112
+ "t0"."created_at" <= '2019-03-04' AND
113
+ "t0"."created_at" < '2018-03-04' AND
114
+ "t0"."created_at" >= '2001-03-04' AND
115
+ "t0"."created_at" > '2002-03-04' AND
116
+ ("t0"."name" != 'Netflix' OR "t0"."name" != 'Hulu') AND
117
+ ("t0"."name" NOT LIKE '%tfli%' OR "t0"."name" NOT LIKE '%ul%') AND
118
+ ("t0"."name" NOT LIKE 'netf%' OR "t0"."name" NOT LIKE 'hu%')
119
+ mysql_readable: |+
120
+ SELECT
121
+ `theaters`.`id` AS 'ID #',
122
+ `theaters`.`name` AS 'name'
123
+ FROM `theaters` `theaters`
124
+ WHERE
125
+ (`theaters`.`name` = 'AMC' OR `theaters`.`name` = 'Regal') AND
126
+ `theaters`.`name` LIKE 'A%' AND
127
+ `theaters`.`name` LIKE '%m%' AND
128
+ `theaters`.`active` = FALSE AND
129
+ (((((`theaters`.`active` = FALSE OR `theaters`.`active` = TRUE) OR
130
+ `theaters`.`active` = FALSE) OR `theaters`.`active` = TRUE) OR
131
+ `theaters`.`active` = FALSE) OR
132
+ `theaters`.`active` = FALSE) AND
133
+ (((((`theaters`.`inspected` = FALSE OR `theaters`.`inspected` = TRUE) OR
134
+ `theaters`.`inspected` IS NULL) OR
135
+ `theaters`.`inspected` = TRUE) OR
136
+ `theaters`.`inspected` = FALSE) OR
137
+ `theaters`.`inspected` IS NULL) AND
138
+ `theaters`.`created_at` <= '2019-03-04' AND
139
+ `theaters`.`created_at` < '2018-03-04' AND
140
+ `theaters`.`created_at` >= '2001-03-04' AND
141
+ `theaters`.`created_at` > '2002-03-04' AND
142
+ (`theaters`.`name` != 'Netflix' OR `theaters`.`name` != 'Hulu') AND
143
+ (`theaters`.`name` NOT LIKE '%tfli%' OR `theaters`.`name` NOT LIKE '%ul%') AND
144
+ (`theaters`.`name` NOT LIKE 'netf%' OR `theaters`.`name` NOT LIKE 'hu%')
145
+ mysql_not_readable: |+
146
+ SELECT
147
+ `t0`.`id` AS 'c0',
148
+ `t0`.`name` AS 'c1'
149
+ FROM `theaters` `t0`
150
+ WHERE
151
+ (`t0`.`name` = 'AMC' OR `t0`.`name` = 'Regal') AND
152
+ `t0`.`name` LIKE 'A%' AND
153
+ `t0`.`name` LIKE '%m%' AND
154
+ `t0`.`active` = FALSE AND
155
+ (((((`t0`.`active` = FALSE OR `t0`.`active` = TRUE) OR
156
+ `t0`.`active` = FALSE) OR `t0`.`active` = TRUE) OR
157
+ `t0`.`active` = FALSE) OR
158
+ `t0`.`active` = FALSE) AND
159
+ (((((`t0`.`inspected` = FALSE OR `t0`.`inspected` = TRUE) OR
160
+ `t0`.`inspected` IS NULL) OR
161
+ `t0`.`inspected` = TRUE) OR
162
+ `t0`.`inspected` = FALSE) OR
163
+ `t0`.`inspected` IS NULL) AND
164
+ `t0`.`created_at` <= '2019-03-04' AND
165
+ `t0`.`created_at` < '2018-03-04' AND
166
+ `t0`.`created_at` >= '2001-03-04' AND
167
+ `t0`.`created_at` > '2002-03-04' AND
168
+ (`t0`.`name` != 'Netflix' OR `t0`.`name` != 'Hulu') AND
169
+ (`t0`.`name` NOT LIKE '%tfli%' OR `t0`.`name` NOT LIKE '%ul%') AND
170
+ (`t0`.`name` NOT LIKE 'netf%' OR `t0`.`name` NOT LIKE 'hu%')
@@ -0,0 +1,30 @@
1
+ model_name: Theaters, Members, and Movies
2
+ query:
3
+ fields:
4
+ - key_path: id
5
+ - key_path: name
6
+ limit: 123
7
+ sqlite_readable: |+
8
+ SELECT
9
+ "theaters"."id" AS 'id',
10
+ "theaters"."name" AS 'name'
11
+ FROM "theaters" "theaters"
12
+ LIMIT 123
13
+ sqlite_not_readable: |+
14
+ SELECT
15
+ "t0"."id" AS 'c0',
16
+ "t0"."name" AS 'c1'
17
+ FROM "theaters" "t0"
18
+ LIMIT 123
19
+ mysql_readable: |+
20
+ SELECT
21
+ `theaters`.`id` AS 'id',
22
+ `theaters`.`name` AS 'name'
23
+ FROM `theaters` `theaters`
24
+ LIMIT 123
25
+ mysql_not_readable: |+
26
+ SELECT
27
+ `t0`.`id` AS 'c0',
28
+ `t0`.`name` AS 'c1'
29
+ FROM `theaters` `t0`
30
+ LIMIT 123
@@ -0,0 +1,33 @@
1
+ model_name: Theaters, Members, and Movies
2
+ query:
3
+ fields:
4
+ - key_path: id
5
+ - key_path: name
6
+ sorters:
7
+ - key_path: created_at
8
+ - key_path: name
9
+ direction: descending
10
+ sqlite_readable: |+
11
+ SELECT
12
+ "theaters"."id" AS 'id',
13
+ "theaters"."name" AS 'name'
14
+ FROM "theaters" "theaters"
15
+ ORDER BY "theaters"."created_at", "theaters"."name" DESC
16
+ sqlite_not_readable: |+
17
+ SELECT
18
+ "t0"."id" AS 'c0',
19
+ "t0"."name" AS 'c1'
20
+ FROM "theaters" "t0"
21
+ ORDER BY "t0"."created_at", "t0"."name" DESC
22
+ mysql_readable: |+
23
+ SELECT
24
+ `theaters`.`id` AS 'id',
25
+ `theaters`.`name` AS 'name'
26
+ FROM `theaters` `theaters`
27
+ ORDER BY `theaters`.`created_at`, `theaters`.`name` DESC
28
+ mysql_not_readable: |+
29
+ SELECT
30
+ `t0`.`id` AS 'c0',
31
+ `t0`.`name` AS 'c1'
32
+ FROM `theaters` `t0`
33
+ ORDER BY `t0`.`created_at`, `t0`.`name` DESC
@@ -0,0 +1,44 @@
1
+ model_name: Theaters, Members, and Movies
2
+ query:
3
+ fields:
4
+ - key_path: id
5
+ - key_path: name
6
+ - key_path: members.id
7
+ - key_path: members.account_number
8
+ limit: 12
9
+ sqlite_readable: |+
10
+ SELECT
11
+ "theaters"."id" AS 'id',
12
+ "theaters"."name" AS 'name',
13
+ "members"."id" AS 'members_id',
14
+ "members"."account_number" AS 'members_account_number'
15
+ FROM "theaters" "theaters"
16
+ LEFT OUTER JOIN "members" "members" ON "members"."tid" = "theaters"."id" AND "members"."partition" = "theaters"."partition"
17
+ LIMIT 12
18
+ sqlite_not_readable: |+
19
+ SELECT
20
+ "t0"."id" AS 'c0',
21
+ "t0"."name" AS 'c1',
22
+ "t1"."id" AS 'c2',
23
+ "t1"."account_number" AS 'c3'
24
+ FROM "theaters" "t0"
25
+ LEFT OUTER JOIN "members" "t1" ON "t1"."tid" = "t0"."id" AND "t1"."partition" = "t0"."partition"
26
+ LIMIT 12
27
+ mysql_readable: |+
28
+ SELECT
29
+ `theaters`.`id` AS 'id',
30
+ `theaters`.`name` AS 'name',
31
+ `members`.`id` AS 'members_id',
32
+ `members`.`account_number` AS 'members_account_number'
33
+ FROM `theaters` `theaters`
34
+ LEFT OUTER JOIN `members` `members` ON `members`.`tid` = `theaters`.`id` AND `members`.`partition` = `theaters`.`partition`
35
+ LIMIT 12
36
+ mysql_not_readable: |+
37
+ SELECT
38
+ `t0`.`id` AS 'c0',
39
+ `t0`.`name` AS 'c1',
40
+ `t1`.`id` AS 'c2',
41
+ `t1`.`account_number` AS 'c3'
42
+ FROM `theaters` `t0`
43
+ LEFT OUTER JOIN `members` `t1` ON `t1`.`tid` = `t0`.`id` AND `t1`.`partition` = `t0`.`partition`
44
+ LIMIT 12
@@ -0,0 +1,66 @@
1
+ Theaters, Members, and Movies:
2
+ name: theaters
3
+ table: theaters
4
+ columns:
5
+ - name: active
6
+ type: boolean
7
+ nullable: false
8
+ - name: inspected
9
+ type: boolean # this one is nullable
10
+ models:
11
+ - name: members
12
+ table: members
13
+ constraints:
14
+ - type: reference
15
+ parent: id
16
+ name: tid
17
+ - type: reference
18
+ parent: partition
19
+ name: partition
20
+ models:
21
+ - name: demos
22
+ table: demographics
23
+ constraints:
24
+ - type: reference
25
+ parent: id
26
+ name: member_id
27
+ models:
28
+ - name: phone_numbers
29
+ table: phone_numbers
30
+ constraints:
31
+ - type: reference
32
+ parent: id
33
+ name: demographic_id
34
+ - name: movies
35
+ table: movies
36
+ constraints:
37
+ - type: reference
38
+ parent: id
39
+ name: member_id
40
+ - name: favorite_comic_movies
41
+ table: movies
42
+ constraints:
43
+ - type: reference
44
+ parent: id
45
+ name: member_id
46
+ - type: static
47
+ name: genre
48
+ value: comic
49
+ - name: favorite_mystery_movies
50
+ table: movies
51
+ constraints:
52
+ - type: reference
53
+ parent: id
54
+ name: member_id
55
+ - type: static
56
+ name: genre
57
+ value: mystery
58
+ - name: favorite_comedy_movies
59
+ table: movies
60
+ constraints:
61
+ - type: reference
62
+ parent: id
63
+ name: member_id
64
+ - type: static
65
+ name: genre
66
+ value: comedy
@@ -0,0 +1,52 @@
1
+ # frozen_string_literal: true
2
+
3
+ #
4
+ # Copyright (c) 2018-present, Blue Marble Payroll, LLC
5
+ #
6
+ # This source code is licensed under the MIT license found in the
7
+ # LICENSE file in the root directory of this source tree.
8
+ #
9
+
10
+ require 'yaml'
11
+ require 'pry'
12
+
13
+ unless ENV['DISABLE_SIMPLECOV'] == 'true'
14
+ require 'simplecov'
15
+ require 'simplecov-console'
16
+
17
+ SimpleCov.formatter = SimpleCov::Formatter::Console
18
+ SimpleCov.start do
19
+ add_filter %r{\A/spec/}
20
+ end
21
+ end
22
+
23
+ require './lib/dbee/providers/active_record_provider'
24
+
25
+ def fixture_path(*filename)
26
+ File.join('spec', 'fixtures', filename)
27
+ end
28
+
29
+ def yaml_fixture(*filename)
30
+ YAML.safe_load(fixture(*filename))
31
+ end
32
+
33
+ def fixture(*filename)
34
+ File.open(fixture_path(*filename), 'r:bom|utf-8').read
35
+ end
36
+
37
+ def yaml_fixture_files(*directory)
38
+ Dir[File.join('spec', 'fixtures', *directory, '*.yaml')].map do |filename|
39
+ [
40
+ filename,
41
+ yaml_file_read(filename)
42
+ ]
43
+ end.to_h
44
+ end
45
+
46
+ def yaml_file_read(*filename)
47
+ YAML.safe_load(file_read(*filename))
48
+ end
49
+
50
+ def file_read(*filename)
51
+ File.open(File.join(*filename), 'r:bom|utf-8').read
52
+ end
metadata ADDED
@@ -0,0 +1,256 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: dbee-active_record
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0.pre.alpha
5
+ platform: ruby
6
+ authors:
7
+ - Matthew Ruggio
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2019-08-20 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activerecord
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '5'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 5.2.1
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '5'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 5.2.1
33
+ - !ruby/object:Gem::Dependency
34
+ name: dbee
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: 1.0.0.pre.alpha.1
40
+ type: :runtime
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: 1.0.0.pre.alpha.1
47
+ - !ruby/object:Gem::Dependency
48
+ name: guard-rspec
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '4.7'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - "~>"
59
+ - !ruby/object:Gem::Version
60
+ version: '4.7'
61
+ - !ruby/object:Gem::Dependency
62
+ name: mysql2
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '0.5'
68
+ type: :development
69
+ prerelease: false
70
+ version_requirements: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '0.5'
75
+ - !ruby/object:Gem::Dependency
76
+ name: pry
77
+ requirement: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - "~>"
80
+ - !ruby/object:Gem::Version
81
+ version: '0'
82
+ type: :development
83
+ prerelease: false
84
+ version_requirements: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - "~>"
87
+ - !ruby/object:Gem::Version
88
+ version: '0'
89
+ - !ruby/object:Gem::Dependency
90
+ name: rake
91
+ requirement: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - "~>"
94
+ - !ruby/object:Gem::Version
95
+ version: '12'
96
+ type: :development
97
+ prerelease: false
98
+ version_requirements: !ruby/object:Gem::Requirement
99
+ requirements:
100
+ - - "~>"
101
+ - !ruby/object:Gem::Version
102
+ version: '12'
103
+ - !ruby/object:Gem::Dependency
104
+ name: rspec
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: '3.8'
110
+ type: :development
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - "~>"
115
+ - !ruby/object:Gem::Version
116
+ version: '3.8'
117
+ - !ruby/object:Gem::Dependency
118
+ name: rubocop
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - "~>"
122
+ - !ruby/object:Gem::Version
123
+ version: 0.63.1
124
+ type: :development
125
+ prerelease: false
126
+ version_requirements: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: 0.63.1
131
+ - !ruby/object:Gem::Dependency
132
+ name: simplecov
133
+ requirement: !ruby/object:Gem::Requirement
134
+ requirements:
135
+ - - "~>"
136
+ - !ruby/object:Gem::Version
137
+ version: 0.16.1
138
+ type: :development
139
+ prerelease: false
140
+ version_requirements: !ruby/object:Gem::Requirement
141
+ requirements:
142
+ - - "~>"
143
+ - !ruby/object:Gem::Version
144
+ version: 0.16.1
145
+ - !ruby/object:Gem::Dependency
146
+ name: simplecov-console
147
+ requirement: !ruby/object:Gem::Requirement
148
+ requirements:
149
+ - - "~>"
150
+ - !ruby/object:Gem::Version
151
+ version: 0.4.2
152
+ type: :development
153
+ prerelease: false
154
+ version_requirements: !ruby/object:Gem::Requirement
155
+ requirements:
156
+ - - "~>"
157
+ - !ruby/object:Gem::Version
158
+ version: 0.4.2
159
+ - !ruby/object:Gem::Dependency
160
+ name: sqlite3
161
+ requirement: !ruby/object:Gem::Requirement
162
+ requirements:
163
+ - - "~>"
164
+ - !ruby/object:Gem::Version
165
+ version: '1'
166
+ type: :development
167
+ prerelease: false
168
+ version_requirements: !ruby/object:Gem::Requirement
169
+ requirements:
170
+ - - "~>"
171
+ - !ruby/object:Gem::Version
172
+ version: '1'
173
+ description: " By default Dbee ships with no underlying SQL generator. This library
174
+ will plug in ActiveRecord into Dbee and Dbee will use it for SQL generation.\n"
175
+ email:
176
+ - mruggio@bluemarblepayroll.com
177
+ executables:
178
+ - console
179
+ extensions: []
180
+ extra_rdoc_files: []
181
+ files:
182
+ - ".editorconfig"
183
+ - ".gitignore"
184
+ - ".rubocop.yml"
185
+ - ".ruby-version"
186
+ - ".travis.yml"
187
+ - CHANGELOG.md
188
+ - CODE_OF_CONDUCT.md
189
+ - Gemfile
190
+ - Guardfile
191
+ - LICENSE
192
+ - README.md
193
+ - Rakefile
194
+ - bin/console
195
+ - dbee-active_record.gemspec
196
+ - lib/dbee/providers/active_record_provider.rb
197
+ - lib/dbee/providers/active_record_provider/expression_builder.rb
198
+ - lib/dbee/providers/active_record_provider/expression_builder/constraint_maker.rb
199
+ - lib/dbee/providers/active_record_provider/expression_builder/order_maker.rb
200
+ - lib/dbee/providers/active_record_provider/expression_builder/select_maker.rb
201
+ - lib/dbee/providers/active_record_provider/expression_builder/where_maker.rb
202
+ - lib/dbee/providers/active_record_provider/obfuscated_alias_maker.rb
203
+ - lib/dbee/providers/active_record_provider/safe_alias_maker.rb
204
+ - lib/dbee/providers/active_record_provider/version.rb
205
+ - spec/config/database.yaml.ci
206
+ - spec/db_helper.rb
207
+ - spec/dbee/providers/active_record_provider_spec.rb
208
+ - spec/fixtures/active_record_snapshots/five_table_query.yaml
209
+ - spec/fixtures/active_record_snapshots/multiple_same_table_query_with_static_constraints.yaml
210
+ - spec/fixtures/active_record_snapshots/one_table_query.yaml
211
+ - spec/fixtures/active_record_snapshots/one_table_query_with_ascending_sort.yaml
212
+ - spec/fixtures/active_record_snapshots/one_table_query_with_descending_sort.yaml
213
+ - spec/fixtures/active_record_snapshots/one_table_query_with_filters.yaml
214
+ - spec/fixtures/active_record_snapshots/one_table_query_with_limit.yaml
215
+ - spec/fixtures/active_record_snapshots/one_table_query_with_multiple_sorts.yaml
216
+ - spec/fixtures/active_record_snapshots/two_table_query.yaml
217
+ - spec/fixtures/models.yaml
218
+ - spec/spec_helper.rb
219
+ homepage: https://github.com/bluemarblepayroll/dbee-active_record
220
+ licenses:
221
+ - MIT
222
+ metadata: {}
223
+ post_install_message:
224
+ rdoc_options: []
225
+ require_paths:
226
+ - lib
227
+ required_ruby_version: !ruby/object:Gem::Requirement
228
+ requirements:
229
+ - - ">="
230
+ - !ruby/object:Gem::Version
231
+ version: 2.3.8
232
+ required_rubygems_version: !ruby/object:Gem::Requirement
233
+ requirements:
234
+ - - ">"
235
+ - !ruby/object:Gem::Version
236
+ version: 1.3.1
237
+ requirements: []
238
+ rubygems_version: 3.0.3
239
+ signing_key:
240
+ specification_version: 4
241
+ summary: Plugs in ActiveRecord so Dbee can use Arel for SQL generation.
242
+ test_files:
243
+ - spec/config/database.yaml.ci
244
+ - spec/db_helper.rb
245
+ - spec/dbee/providers/active_record_provider_spec.rb
246
+ - spec/fixtures/active_record_snapshots/five_table_query.yaml
247
+ - spec/fixtures/active_record_snapshots/multiple_same_table_query_with_static_constraints.yaml
248
+ - spec/fixtures/active_record_snapshots/one_table_query.yaml
249
+ - spec/fixtures/active_record_snapshots/one_table_query_with_ascending_sort.yaml
250
+ - spec/fixtures/active_record_snapshots/one_table_query_with_descending_sort.yaml
251
+ - spec/fixtures/active_record_snapshots/one_table_query_with_filters.yaml
252
+ - spec/fixtures/active_record_snapshots/one_table_query_with_limit.yaml
253
+ - spec/fixtures/active_record_snapshots/one_table_query_with_multiple_sorts.yaml
254
+ - spec/fixtures/active_record_snapshots/two_table_query.yaml
255
+ - spec/fixtures/models.yaml
256
+ - spec/spec_helper.rb