metasploit-erd 3.0.2 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/Gemfile +0 -2
- data/lib/metasploit/erd/entity/namespace.rb +2 -2
- data/lib/metasploit/erd/version.rb +1 -1
- data/metasploit-erd.gemspec +2 -2
- data/spec/metasploit/erd/relationship_spec.rb +1 -6
- data/spec/support/shared/contexts/active_record_base_connection.rb +2 -2
- data/spec/support/shared/contexts/active_record_base_descendants_cleaner.rb +8 -2
- metadata +5 -5
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0cbc0c8942a56262c657c4999b6a41aef1c8d98178398e58c395340fb0572094
|
4
|
+
data.tar.gz: 911e2e4a3f8300a70ed7a89743d774c694f25b360009d63f8969ee8911e0430d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9aff92fe3185e89966f4f7ddda211704a12740f6abec91d4d2afe25417486b627a53d987f848583f48095eed355e03f86435348aa8bb4c2c066987a9e63207ef
|
7
|
+
data.tar.gz: bb38953c08d8ffd8a74355c71b464c0fd4a093e9d110e1356b77686dfea7f0751c271a60586cff1438f1acb9475bf2091673338d088db9a3437373a37d7a50c3
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/Gemfile
CHANGED
@@ -31,7 +31,7 @@ class Metasploit::ERD::Entity::Namespace
|
|
31
31
|
# @return [Array<Class<ActiveRecord::Base>
|
32
32
|
def classes
|
33
33
|
ActiveRecord::Base.descendants.select { |klass|
|
34
|
-
klass.
|
34
|
+
klass.module_parents.any? { |parent|
|
35
35
|
parent.name == namespace_name
|
36
36
|
}
|
37
37
|
}
|
@@ -63,4 +63,4 @@ class Metasploit::ERD::Entity::Namespace
|
|
63
63
|
|
64
64
|
super(super_options)
|
65
65
|
end
|
66
|
-
end
|
66
|
+
end
|
data/metasploit-erd.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
|
|
25
25
|
spec.add_development_dependency 'rake'
|
26
26
|
spec.add_development_dependency 'rspec'
|
27
27
|
|
28
|
-
spec.add_runtime_dependency 'activerecord', '~>
|
29
|
-
spec.add_runtime_dependency 'activesupport', '~>
|
28
|
+
spec.add_runtime_dependency 'activerecord', '~> 6.0'
|
29
|
+
spec.add_runtime_dependency 'activesupport', '~> 6.0'
|
30
30
|
spec.add_runtime_dependency 'rails-erd'
|
31
31
|
end
|
@@ -124,13 +124,10 @@ RSpec.describe Metasploit::ERD::Relationship do
|
|
124
124
|
|
125
125
|
ActiveRecord::Migration.create_table :owners do |t|
|
126
126
|
t.references :thing
|
127
|
-
|
128
|
-
t.timestamp
|
129
127
|
end
|
130
128
|
|
131
129
|
things.each do |thing|
|
132
130
|
ActiveRecord::Migration.create_table thing.table_name do |t|
|
133
|
-
t.timestamp
|
134
131
|
end
|
135
132
|
end
|
136
133
|
end
|
@@ -210,8 +207,6 @@ RSpec.describe Metasploit::ERD::Relationship do
|
|
210
207
|
group_names.each do |group_name|
|
211
208
|
t.references group_name.underscore.to_sym
|
212
209
|
end
|
213
|
-
|
214
|
-
t.timestamp
|
215
210
|
end
|
216
211
|
|
217
212
|
polymorphics_by_group_name.each do |group_name, polymorphics|
|
@@ -241,4 +236,4 @@ RSpec.describe Metasploit::ERD::Relationship do
|
|
241
236
|
end
|
242
237
|
end
|
243
238
|
end
|
244
|
-
end
|
239
|
+
end
|
@@ -6,6 +6,12 @@ RSpec.shared_context 'ActiveRecord::Base.descendants cleaner' do
|
|
6
6
|
after(:example) do
|
7
7
|
# `ActiveSupport::DescendantsTracker.clear` will not clear ActiveRecord::Base subclasses because
|
8
8
|
# ActiveSupport::Dependencies is loaded
|
9
|
-
ActiveRecord::
|
9
|
+
if ActiveRecord.version >= Gem::Version.new("6.0.0.rc1")
|
10
|
+
cv = ActiveSupport::DescendantsTracker.class_variable_get(:@@direct_descendants)
|
11
|
+
cv.delete(ActiveRecord::Base)
|
12
|
+
ActiveSupport::DescendantsTracker.class_variable_set(:@@direct_descendants, cv)
|
13
|
+
else
|
14
|
+
ActiveRecord::Base.direct_descendants.clear
|
15
|
+
end
|
10
16
|
end
|
11
|
-
end
|
17
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metasploit-erd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Metasploit Hackers
|
@@ -143,28 +143,28 @@ dependencies:
|
|
143
143
|
requirements:
|
144
144
|
- - "~>"
|
145
145
|
- !ruby/object:Gem::Version
|
146
|
-
version:
|
146
|
+
version: '6.0'
|
147
147
|
type: :runtime
|
148
148
|
prerelease: false
|
149
149
|
version_requirements: !ruby/object:Gem::Requirement
|
150
150
|
requirements:
|
151
151
|
- - "~>"
|
152
152
|
- !ruby/object:Gem::Version
|
153
|
-
version:
|
153
|
+
version: '6.0'
|
154
154
|
- !ruby/object:Gem::Dependency
|
155
155
|
name: activesupport
|
156
156
|
requirement: !ruby/object:Gem::Requirement
|
157
157
|
requirements:
|
158
158
|
- - "~>"
|
159
159
|
- !ruby/object:Gem::Version
|
160
|
-
version:
|
160
|
+
version: '6.0'
|
161
161
|
type: :runtime
|
162
162
|
prerelease: false
|
163
163
|
version_requirements: !ruby/object:Gem::Requirement
|
164
164
|
requirements:
|
165
165
|
- - "~>"
|
166
166
|
- !ruby/object:Gem::Version
|
167
|
-
version:
|
167
|
+
version: '6.0'
|
168
168
|
- !ruby/object:Gem::Dependency
|
169
169
|
name: rails-erd
|
170
170
|
requirement: !ruby/object:Gem::Requirement
|
metadata.gz.sig
CHANGED
Binary file
|