faithfulgeek-rspec-make-out 0.1.0 → 0.3.0

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.
data/README.textile ADDED
@@ -0,0 +1,27 @@
1
+ h1. rspec-make-out
2
+
3
+ Get your rspec output in a make-friendly format. Makes _real_ editors (Emacs, Vim, etc?) play nicely with failing specs by jumping you to the line that failed.
4
+
5
+ h2. Format
6
+
7
+ *Passing spec*
8
+
9
+ _no output_
10
+
11
+ *Failing spec*
12
+
13
+ _filename_:_line number_: _example description_ (FAILED|ERROR - 1)
14
+
15
+
16
+ h1. Authors
17
+
18
+ Jonathan Penn (http://www.wavethenavel.com)
19
+ Joe Fiorini (http://faithfulgeek.org)
20
+
21
+ h1. Acknowledgments
22
+
23
+ "Gary Bernhardt":http://blog.extracheese.org for his inspiration to make this.
24
+
25
+ == Copyright
26
+
27
+ Copyright (c) 2009 faithfulgeek. See LICENSE for details.
data/VERSION.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  ---
2
2
  :major: 0
3
- :minor: 1
3
+ :minor: 3
4
4
  :patch: 0
@@ -19,16 +19,21 @@ module Spec
19
19
  def example_failed(example, counter, failure)
20
20
  spec_backtrace_line = failure.exception.backtrace.find{|l| l =~ /_spec.rb/}
21
21
 
22
- message = if failure.expectation_not_met?
23
- "#{spec_backtrace_line}:#{@current_group} - #{example.description} (FAILED - #{counter})"
24
- else
25
- "#{spec_backtrace_line}:#{@current_group} - #{example.description} (ERROR - #{counter})"
26
- end
22
+ files = failure.exception.backtrace
27
23
 
28
- output.puts(failure.expectation_not_met? ? red(message) : magenta(message))
24
+ message_type = if failure.expectation_not_met? then "FAILED" else "ERROR" end
25
+ message = files.map do |file|
26
+ "#{file}:#{failure.exception}"
27
+ end.join("\n")
28
+
29
+
30
+ output.puts(message)
29
31
  exit
30
32
  end
31
33
 
34
+ def example_pending(*args)
35
+ end
36
+
32
37
  def dump_failure(counter, failure)
33
38
  end
34
39
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: faithfulgeek-rspec-make-out
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - faithfulgeek
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2009-05-03 00:00:00 -07:00
13
+ date: 2009-05-04 00:00:00 -07:00
14
14
  default_executable:
15
15
  dependencies: []
16
16
 
@@ -22,10 +22,10 @@ extensions: []
22
22
 
23
23
  extra_rdoc_files:
24
24
  - LICENSE
25
- - README.rdoc
25
+ - README.textile
26
26
  files:
27
27
  - LICENSE
28
- - README.rdoc
28
+ - README.textile
29
29
  - Rakefile
30
30
  - VERSION.yml
31
31
  - lib/rspec_make_out.rb
data/README.rdoc DELETED
@@ -1,7 +0,0 @@
1
- = rspec-make-out
2
-
3
- Description goes here.
4
-
5
- == Copyright
6
-
7
- Copyright (c) 2009 faithfulgeek. See LICENSE for details.