simple-service 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 706a23842071b121c2b6298b7bdaec0b43c4b110125c2c09011537541c4f5b9b
4
- data.tar.gz: 9ad938ece973392233c554053aa1906da0ea799722d527cb15870913ef108070
3
+ metadata.gz: d65e66415fb2f397d259653690c278d2322d196433617694df746fabc31a3e13
4
+ data.tar.gz: 1c37a1564e0cfd743eba8ff453b6659e4bd4cc6d82b240c095931b3b6eb5ec26
5
5
  SHA512:
6
- metadata.gz: 68563b2c8d9c955049814f90d31b765a30c077553d7199287c4d0117d7d1ed0eb2ce71674195820d482de52bd2f53c70dbb798549d2bf6a7c35ef2f149de3b56
7
- data.tar.gz: ccb9fc69a58b3a9f7225e60e1b8120dced8ec58802483ee4151cb6a0fc71c20b5b3f9b4393b6b9c09de2ec18d3c09bfbdac16f341669ac055b3daa9b31b98ae0
6
+ metadata.gz: 32271afe6c145349999b772d8d9981cd09895e78228a01fa8d22a3103fd4a8ea1e198f7e24a69681a6068b00c7f81b7944a613efc5fb7f9bdbb5d7221fa42f0b
7
+ data.tar.gz: 8ed02caac30787e6e9dc62491374f1bd75a9116c29b4091bb4027336b28e53f0499918b95d45d5961d3e52f405e5a099f448c2461180e8f170b35f1f33032a41
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.0
1
+ 0.2.1
@@ -81,6 +81,12 @@ module Simple::Service
81
81
  positionals = build_positional_arguments(args, flags)
82
82
  keywords = build_keyword_arguments(args.merge(flags))
83
83
 
84
+ # check for extra flags
85
+ extra_flags = (flags.keys - keywords.keys.map(&:to_s)).map { |flag| "--#{flag}" }
86
+ unless extra_flags.empty?
87
+ raise Simple::Service::ArgumentError, "Unknown flag(s): #{extra_flags.join(", ")}."
88
+ end
89
+
84
90
  service_instance = Object.new
85
91
  service_instance.extend service
86
92
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple-service
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - radiospiel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-10-06 00:00:00.000000000 Z
11
+ date: 2022-06-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: expectation