scudco-taglob 1.0.2 → 1.1.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/History.txt CHANGED
@@ -1,3 +1,8 @@
1
+ === 1.1.0 / 2008-11-17
2
+ * New Feature
3
+ * TagHtmlFormatter opens up the RSpec HTML Formatter to print the tags environment variable which useful if you do something like:
4
+ $ rake spec_tag tags="foo,bar,baz" SPEC_OPTS='-r rubygems,taglob/spec/tag_html_formatter'
5
+
1
6
  === 1.0.2 / 2008-11-04
2
7
 
3
8
  * Minor Changes
data/Manifest.txt CHANGED
@@ -12,6 +12,7 @@ lib/taglob/rake.rb
12
12
  lib/taglob/rake/check_tags_task.rb
13
13
  lib/taglob/rake/tasks.rb
14
14
  lib/taglob/rake/test_tags_task.rb
15
+ lib/taglob/spec/tag_html_formatter.rb
15
16
  spec/check_tags_task_spec.rb
16
17
  spec/dir_tagor_spec.rb
17
18
  spec/missing_tags.txt
@@ -0,0 +1,24 @@
1
+ # To display tag information while running the specs
2
+ # USAGE : Set the tags first if using in command line
3
+ # $ export tags=foo then run spec with following options
4
+ #["--require rubygems,taglob/spec/tag_html_formatter --format TagHtmlFormatter:#{file_name}"]
5
+ # Example:
6
+ # $ spec --require rubygems,taglob/spec/tag_html_formatter --format TagHtmlFormatter:#{file_name}.html
7
+
8
+ require 'spec/runner/formatter/html_formatter'
9
+
10
+ class Spec::Runner::Formatter::HtmlFormatter
11
+ alias :original_report_header :report_header
12
+ alias :original_global_styles :global_styles
13
+ def report_header
14
+ if ENV['tags'].nil?
15
+ original_report_header
16
+ else
17
+ original_report_header + "<div id='tag-header'><h3>These specs contain the following tags: #{ENV['tags']}</h3></div>"
18
+ end
19
+ end
20
+
21
+ def global_styles
22
+ original_global_styles + ".rspec-report h3 {margin: 0px 10px 0px 10px; padding: 10px;font: normal 11px ,'Lucida Grande', Helvetica, sans-serif;font-size: 1.2em;}"
23
+ end
24
+ end
data/lib/taglob.rb CHANGED
@@ -18,7 +18,7 @@
18
18
  require 'taglob/extensions'
19
19
 
20
20
  module Taglob
21
- VERSION = '1.0.2'
21
+ VERSION = '1.1.0'
22
22
 
23
23
  def self.invalid_tags(pattern,valid_tags)
24
24
  invalids = {}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scudco-taglob
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adam Anderson
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2008-11-04 00:00:00 -08:00
12
+ date: 2008-11-17 00:00:00 -08:00
13
13
  default_executable: taglob
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -48,6 +48,7 @@ files:
48
48
  - lib/taglob/rake/check_tags_task.rb
49
49
  - lib/taglob/rake/tasks.rb
50
50
  - lib/taglob/rake/test_tags_task.rb
51
+ - lib/taglob/spec/tag_html_formatter.rb
51
52
  - spec/check_tags_task_spec.rb
52
53
  - spec/dir_tagor_spec.rb
53
54
  - spec/missing_tags.txt