pry_testcase 0.2.0 → 0.3.0

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
  SHA1:
3
- metadata.gz: 7eb6787530ce83c9de60cafddacc350b7fcb64fb
4
- data.tar.gz: 4618e1b167045a1c140ccf7430e203641279d625
3
+ metadata.gz: 4c4409191519b1641563e1537c0675339ab28b05
4
+ data.tar.gz: 54b478f0e536bff212cc68281da616ea4be7edd7
5
5
  SHA512:
6
- metadata.gz: f56e52c84dbd462db309ce68814c1274045124cbbb506164c9be191e2f3635f5f6f879175a05988fef302a4a196961eca027b6e049293d12079935f32ac9de72
7
- data.tar.gz: 878f9afec873ba1ba6317248e64a32a8bdabf0b2a78afce3856f899e420b6af082fbdd9d02c133457e50ac58ef329f173ffef19a893815da5792e71904aa5082
6
+ metadata.gz: e9a45ef31cc1d28abd929c6331bc18847ca25711998bd4e42252bbe22a86a24d59b2ce3793c50962f04a2c71174c9dd8c874133d4297c2da62cc61aedbb3b976
7
+ data.tar.gz: 5ae2d4b40f6f9706c4fd64c8f8926019a69555ecf5bb657e0b4acc8e41072def42a9b8b07233d440414ed12bedfdbd21dc71928038b742eaf7c739aff24351fb
data/README.md CHANGED
@@ -37,6 +37,11 @@ def say(msg, param)
37
37
  end
38
38
  ```
39
39
 
40
+ ```ruby
41
+ # spec_helper.rb
42
+ require 'pry_testcase/rspec'
43
+ ```
44
+
40
45
  ```ruby
41
46
  describe '#say' do
42
47
  context 'case1' do
@@ -22,7 +22,8 @@ module PryTestcase
22
22
  def pry
23
23
  return unless enabled?
24
24
 
25
- binding.of_caller(1).pry
25
+ depth = caller_locations.find_index{|c| !c.path.end_with?('pry_testcase.rb')} + 1
26
+ binding.of_caller(depth).pry
26
27
  end
27
28
 
28
29
  def pry_once
@@ -1,3 +1,3 @@
1
1
  module PryTestcase
2
- VERSION = "0.2.0"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pry_testcase
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Masataka Kuwabara
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-05-25 00:00:00.000000000 Z
11
+ date: 2016-05-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry