nrser 0.2.1 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a6738d85c4a157986e23fb51cac830faf2998666
4
- data.tar.gz: b8a22cdcdd8b36a3ae2026440b8b4844d28fb9af
3
+ metadata.gz: 3d16770ce888fe9a347449f09975b9ed97eb7ab5
4
+ data.tar.gz: ae0979f9123be24d08b8c45ac6d8c99cc4273603
5
5
  SHA512:
6
- metadata.gz: 1cc98bc014b43e51379d2efb4e51bc50268f97db230fdc3c606e350e27b4666398069c07a35fd2efcfbd52b96097a2e3d82de4ab7ac63273276db5b1293b1482
7
- data.tar.gz: 6fa17fd7b7f57e24da23e2807a3d25c0cff307f84e9c7f793b3ece06eff5f92e7b5592aa5a630525890163c75860f13c96946d21f8180edf981ca546320a3483
6
+ metadata.gz: 9b5106ee53cbf739e2b0b549b5273a6a4057679d261abd0a710679a0e9b6cd95b66794f4afe6a883ccea56fc58afb76d56f38f0b3de385e9dc5da22caa3bc450
7
+ data.tar.gz: e58f6730e248c028c521295b53568485c277abb7ed6191c285b8a44515a0db97f1fe20054e85b4c6c9f2bc38511f5994dbd7cd715c0d2002c06b6e592b6603f0
@@ -138,7 +138,7 @@ class NRSER::Meta::Props::Prop
138
138
  if default.nil?
139
139
  # If it's `nil`, we will use it as the default value *if* this
140
140
  # is a primary prop *and* the type is satisfied by `nil`
141
- @has_default = source? && @type.test( default )
141
+ @has_default = !source? && @type.test( default )
142
142
  return
143
143
  end
144
144
 
@@ -390,11 +390,15 @@ class NRSER::Meta::Props::Prop
390
390
  set instance, default
391
391
  else
392
392
  raise TypeError.new binding.erb <<-ERB
393
- Prop <#= full_name %> has no default value and no value was provided
393
+ Prop <%= full_name %> has no default value and no value was provided
394
394
  in values:
395
395
 
396
396
  <%= values.pretty_inspect %>
397
397
 
398
+ Prop:
399
+
400
+ <%= self.pretty_inspect %>
401
+
398
402
  ERB
399
403
  end
400
404
  end
@@ -16,8 +16,9 @@ module NRSER::RSpex::ExampleGroup
16
16
  metadata: {
17
17
  constructor_args: constructor_args,
18
18
  },
19
- # subject_block: -> { super().new *described_args },
20
- subject_block: -> { super().new *described_constructor_args },
19
+ subject_block: -> {
20
+ described_class.new *described_constructor_args
21
+ },
21
22
  &body
22
23
  end # #describe_instance
23
24
 
@@ -1,5 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ using NRSER
4
+
3
5
  module NRSER::RSpex::ExampleGroup
4
6
 
5
7
  # **EXPERIMENTAL**
data/lib/nrser/version.rb CHANGED
@@ -18,7 +18,7 @@ module NRSER
18
18
  #
19
19
  # @return [String]
20
20
  #
21
- VERSION = '0.2.1'
21
+ VERSION = '0.2.2'
22
22
 
23
23
 
24
24
  module Version
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nrser
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - nrser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-20 00:00:00.000000000 Z
11
+ date: 2018-03-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hamster