grimoire 0.2.10 → 0.2.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/grimoire/solver.rb +7 -0
- data/lib/grimoire/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d9cfc6ad36d174cff8752d6025c8fdd7445c6596
|
4
|
+
data.tar.gz: 90e49128ef18f2b08b043d3b55ff0cf7cd889d4b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5fe68466d8f030a354af88830f985ab74adfc75d4a07352ae3e7cdf57b9334ae06b6d1a5c7b8af721555ec7c43e94de71345982a778054c931d3f517c82bdf2f
|
7
|
+
data.tar.gz: 3e315421c9b172c0eb667e59d5f81372246bbbeb07a2e601cf0c94cde96378fc2c9ae8f780bff6b90ed859dcd1fd9633e8b0a5490c6fe139bf49e70e01225785
|
data/CHANGELOG.md
CHANGED
data/lib/grimoire/solver.rb
CHANGED
@@ -102,6 +102,13 @@ module Grimoire
|
|
102
102
|
end
|
103
103
|
end
|
104
104
|
end
|
105
|
+
missing_new_world = requirements.requirements.find_all do |req|
|
106
|
+
new_world.units[req.name].nil? || new_world.units[req.name].empty?
|
107
|
+
end
|
108
|
+
unless(missing_new_world.empty?)
|
109
|
+
missed_units = missing_new_world.map(&:name).sort
|
110
|
+
raise Error::NoSolution.new "Failed to satisfy core requirements (#{missed_units.join(', ')})"
|
111
|
+
end
|
105
112
|
@world = new_world
|
106
113
|
@new_world = nil
|
107
114
|
self
|
data/lib/grimoire/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grimoire
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Roberts
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bogo
|
@@ -112,3 +112,4 @@ signing_key:
|
|
112
112
|
specification_version: 4
|
113
113
|
summary: Constraint solver
|
114
114
|
test_files: []
|
115
|
+
has_rdoc:
|