dp 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.0
1
+ 1.0.1
data/dp.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{dp}
8
- s.version = "1.0.0"
8
+ s.version = "1.0.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Niclas Nilsson"]
data/lib/dp.rb CHANGED
@@ -11,8 +11,6 @@ class Binding
11
11
  #
12
12
  # ==== Examples
13
13
  #
14
- # # Decrement the post_count column for the record with an id of 5
15
- # DiscussionBoard.decrement_counter(:post_count, 5)
16
14
  # def some_method
17
15
  # name = 'Niclas'
18
16
  # @age = 38
@@ -29,7 +27,7 @@ class Binding
29
27
  variables = debug_str.split(',').map { |v| v.strip }
30
28
  variables.each do |var|
31
29
  result = Kernel.eval var, self
32
- str += "#{separator}#{var}=#{result.inspect.strip}"
30
+ str += "#{separator}#{var}=#{result.inspect}"
33
31
  separator = ', '
34
32
  end
35
33
  puts str
@@ -11,5 +11,11 @@ describe "d.p" do
11
11
  some_method
12
12
  @stdout_string.string.should == 'name="Niclas", @age=38, team=["Niclas", "Johan", "Hans"]' + "\n"
13
13
  end
14
+
15
+ it "should keep whitespace in result" do
16
+ whitespace_method
17
+ @stdout_string.string.should == 'whitespace_string=" foo "' + "\n"
18
+ end
19
+
14
20
  end
15
21
 
@@ -4,7 +4,11 @@ def some_method
4
4
  name = 'Niclas'
5
5
  @age = 38
6
6
  team = ['Niclas', 'Johan', 'Hans']
7
-
7
+
8
8
  d.p "name, @age, team"
9
9
  end
10
-
10
+
11
+ def whitespace_method
12
+ whitespace_string = " foo "
13
+ d.p "whitespace_string"
14
+ end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 1
7
7
  - 0
8
- - 0
9
- version: 1.0.0
8
+ - 1
9
+ version: 1.0.1
10
10
  platform: ruby
11
11
  authors:
12
12
  - Niclas Nilsson