methodist 0.1.0 → 0.1.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: 229590fd037e63ac5773c8a8e11c9ef451d3d01a5cc417c6e97c6c62fe5f30dc
4
- data.tar.gz: acaaf7d57b19ab0b440fb132a43d85bbed2fd838027d2befef5e9d77329dfca2
3
+ metadata.gz: 400d22f7995ef5781b1d534fd188453d8bcb0dd53026327064430ec276622340
4
+ data.tar.gz: d83863d3ea9b248541628f061584ff104098978f1f7953877dd00253196c00e8
5
5
  SHA512:
6
- metadata.gz: 71f861ed48e4a2a390c78c570207ea9ef7fdc00989c383a7dcaec373c951a8a8cef9e165ae8d37bc6b78af50d7bee1edd88e47d9b0f865d39e32b2019d3a9f73
7
- data.tar.gz: ed50190b816143494934cb50018f04e3f88a2e5e8f147bc34956bc7c1c3211a6643dab95f4d85b3d93d0f14a5030d93a7013deb05d9a18d54e6423960e5c1688
6
+ metadata.gz: d6f93df6ae9c00003b2bf09d4de1f52fc088af05abc3feef354462fd667fbacda20f2fd548d35cfeb8d8f27a16081e518c7f023812af2138575fc5c58df62d92
7
+ data.tar.gz: 8cb3b407c467a59952c50e2bd9b2165229e019bc453b27d7a7e8377d7f9c64d24feb90f7e2616aabf96a9e58559363b0bc3079920a2e768774d3162ba8ff4ccc
@@ -18,6 +18,7 @@ class BuilderGenerator < MethodistGenerator
18
18
  end
19
19
 
20
20
  def generate_spec
21
+ return unless rspec_used?
21
22
  template(
22
23
  TEMPLATE_SPEC_FILE,
23
24
  "#{filename_with_path(prefix: 'spec')}_builder_spec.rb"
@@ -19,6 +19,7 @@ class InteractorGenerator < MethodistGenerator
19
19
  end
20
20
 
21
21
  def generate_spec
22
+ return unless rspec_used?
22
23
  template(
23
24
  TEMPLATE_SPEC_FILE,
24
25
  "#{filename_with_path(prefix: 'spec')}_spec.rb"
@@ -15,4 +15,8 @@ class MethodistGenerator < Rails::Generators::NamedBase
15
15
  name = name_as_arr.last
16
16
  "#{prefix}/#{options['path']}/#{path}/#{name}"
17
17
  end
18
+
19
+ def rspec_used?
20
+ defined?(RSpec)
21
+ end
18
22
  end
@@ -18,6 +18,7 @@ class ServiceGenerator < MethodistGenerator
18
18
  end
19
19
 
20
20
  def generate_spec
21
+ return unless rspec_used?
21
22
  template(
22
23
  TEMPLATE_SPEC_FILE,
23
24
  "#{filename_with_path(prefix: 'spec')}_service_spec.rb"
@@ -1,3 +1,3 @@
1
1
  module Methodist
2
- VERSION = '0.1.0'
2
+ VERSION = '0.1.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: methodist
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergey Nesterov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-05-02 00:00:00.000000000 Z
11
+ date: 2018-06-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails