brauser 2.0.0 → 2.0.1

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/.travis-gemfile ADDED
@@ -0,0 +1,13 @@
1
+ # encoding: utf-8
2
+ #
3
+ # This file is part of the brauser gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
4
+ # Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
5
+ #
6
+
7
+ source "http://rubygems.org"
8
+
9
+ gemspec
10
+
11
+ # Testing gems
12
+ gem "rspec", "~> 2.12.0"
13
+ gem "rake", "~> 10.0.3"
data/.travis.yml CHANGED
@@ -1,8 +1,10 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 1.9.2
4
3
  - 1.9.3
5
4
  - 2.0.0
6
- script: bundle exec rake spec:coverage
5
+ - jruby-19mode
6
+ - rbx-19mode
7
+ script: bundle exec rake spec
8
+ gemfile: .travis-gemfile
7
9
  notifications:
8
10
  email: false
data/Gemfile CHANGED
@@ -7,3 +7,14 @@
7
7
  source "http://rubygems.org"
8
8
 
9
9
  gemspec
10
+
11
+ # Testing
12
+ gem "rspec", "~> 2.12.0"
13
+ gem "rake", "~> 10.0.3"
14
+
15
+ # Documentation
16
+ gem "simplecov", ">= 0.7.1"
17
+ gem "pry", ">= 0"
18
+ gem "yard", ">= 0.8.4"
19
+ gem "kramdown", ">= 0.14.2"
20
+ gem "github-markup", ">= 0.7.5"
data/Rakefile CHANGED
@@ -8,11 +8,4 @@ require "bundler/gem_tasks"
8
8
  require "rspec/core/rake_task"
9
9
 
10
10
  RSpec::Core::RakeTask.new("spec")
11
-
12
- namespace :spec do
13
- desc "Run all specs with coverage"
14
- task :coverage do
15
- ENV["BRAUSER_COVERAGE"] = "TRUE"
16
- Rake::Task["spec"].invoke
17
- end
18
- end
11
+ RSpec::Core::RakeTask.new("spec:coverage") { |t| t.ruby_opts = "-r./spec/coverage_helper" }
data/brauser.gemspec CHANGED
@@ -22,15 +22,7 @@ Gem::Specification.new do |gem|
22
22
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
23
23
  gem.require_paths = ["lib"]
24
24
 
25
- gem.required_ruby_version = ">= 1.9.2"
25
+ gem.required_ruby_version = ">= 1.9.3"
26
26
 
27
- gem.add_dependency("lazier", "~> 2.5.0")
28
-
29
- gem.add_development_dependency("rspec", "~> 2.12.0")
30
- gem.add_development_dependency("rake", "~> 10.0.3")
31
- gem.add_development_dependency("simplecov", "~> 0.7.1")
32
- gem.add_development_dependency("pry", ">= 0")
33
- gem.add_development_dependency("yard", "~> 0.8.3")
34
- gem.add_development_dependency("redcarpet", "~> 2.2.2")
35
- gem.add_development_dependency("github-markup", "~> 0.7.5")
27
+ gem.add_dependency("lazier", "~> 2.6.4")
36
28
  end
data/doc/Brauser.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -120,9 +120,9 @@
120
120
  </div>
121
121
 
122
122
  <div id="footer">
123
- Generated on Sat Feb 2 17:47:18 2013 by
123
+ Generated on Fri Feb 8 08:12:31 2013 by
124
124
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
125
- 0.8.3 (ruby-1.9.3).
125
+ 0.8.4.1 (ruby-1.9.3).
126
126
  </div>
127
127
 
128
128
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Brauser::Browser
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -543,11 +543,12 @@
543
543
 
544
544
  <p>For example:</p>
545
545
 
546
- <pre class="code ruby"><code><span class='id identifier rubyid_browser'>browser</span><span class='period'>.</span><span class='id identifier rubyid_is_msie_gt_4_1__on_windows?'>is_msie_gt_4_1__on_windows?</span>
547
- <span class='comment'>#=&gt; true
548
- </span></code></pre>
546
+ <p><code>ruby
547
+ browser.is_msie_gt_4_1__on_windows?
548
+ #=&gt; true
549
+ </code></p>
549
550
 
550
- <p>If you don&#39;t provide a trailing <code>?</code>, you will get a Brauser::Query.</p>
551
+ <p>If you don&#8217;t provide a trailing <code>?</code>, you will get a Brauser::Query.</p>
551
552
 
552
553
  <p>If the syntax is invalid, a <code>NoMethodError</code> exception will be raised.</p>
553
554
 
@@ -2559,9 +2560,9 @@
2559
2560
  </div>
2560
2561
 
2561
2562
  <div id="footer">
2562
- Generated on Sat Feb 2 17:47:19 2013 by
2563
+ Generated on Fri Feb 8 08:12:33 2013 by
2563
2564
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
2564
- 0.8.3 (ruby-1.9.3).
2565
+ 0.8.4.1 (ruby-1.9.3).
2565
2566
  </div>
2566
2567
 
2567
2568
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -116,9 +116,9 @@
116
116
  </div>
117
117
 
118
118
  <div id="footer">
119
- Generated on Sat Feb 2 17:47:18 2013 by
119
+ Generated on Fri Feb 8 08:12:32 2013 by
120
120
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
121
- 0.8.3 (ruby-1.9.3).
121
+ 0.8.4.1 (ruby-1.9.3).
122
122
  </div>
123
123
 
124
124
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::Attributes
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -212,8 +212,9 @@
212
212
 
213
213
  <p>For version, it will be included a class for every token of the version. For example, version <code>7.0.1.2</code> will return this:</p>
214
214
 
215
- <pre class="code ruby"><code><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>version-7</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>version-7_0</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>version-7_0_1</span><span class='tstring_end'>&quot;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>version-7_0_1_2</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span>
216
- </code></pre>
215
+ <p><code>ruby
216
+ ["version-7", "version-7_0", "version-7_0_1", "version-7_0_1_2"]
217
+ </code></p>
217
218
 
218
219
  <p>If you provide a block (with accepts name, version and platform as arguments), it will be used for translating the name.</p>
219
220
 
@@ -475,9 +476,9 @@
475
476
  </div>
476
477
 
477
478
  <div id="footer">
478
- Generated on Sat Feb 2 17:47:19 2013 by
479
+ Generated on Fri Feb 8 08:12:32 2013 by
479
480
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
480
- 0.8.3 (ruby-1.9.3).
481
+ 0.8.4.1 (ruby-1.9.3).
481
482
  </div>
482
483
 
483
484
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::General
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -125,9 +125,9 @@
125
125
  </div>
126
126
 
127
127
  <div id="footer">
128
- Generated on Sat Feb 2 17:47:19 2013 by
128
+ Generated on Fri Feb 8 08:12:32 2013 by
129
129
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
130
- 0.8.3 (ruby-1.9.3).
130
+ 0.8.4.1 (ruby-1.9.3).
131
131
  </div>
132
132
 
133
133
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::General::ClassMethods
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -520,9 +520,9 @@
520
520
  </div>
521
521
 
522
522
  <div id="footer">
523
- Generated on Sat Feb 2 17:47:19 2013 by
523
+ Generated on Fri Feb 8 08:12:32 2013 by
524
524
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
525
- 0.8.3 (ruby-1.9.3).
525
+ 0.8.4.1 (ruby-1.9.3).
526
526
  </div>
527
527
 
528
528
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::Parsing
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -341,9 +341,9 @@
341
341
  </div>
342
342
 
343
343
  <div id="footer">
344
- Generated on Sat Feb 2 17:47:19 2013 by
344
+ Generated on Fri Feb 8 08:12:32 2013 by
345
345
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
346
- 0.8.3 (ruby-1.9.3).
346
+ 0.8.4.1 (ruby-1.9.3).
347
347
  </div>
348
348
 
349
349
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::PartialQuerying
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -620,9 +620,9 @@
620
620
  </div>
621
621
 
622
622
  <div id="footer">
623
- Generated on Sat Feb 2 17:47:19 2013 by
623
+ Generated on Fri Feb 8 08:12:32 2013 by
624
624
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
625
- 0.8.3 (ruby-1.9.3).
625
+ 0.8.4.1 (ruby-1.9.3).
626
626
  </div>
627
627
 
628
628
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::Querying
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -574,9 +574,9 @@
574
574
  </div>
575
575
 
576
576
  <div id="footer">
577
- Generated on Sat Feb 2 17:47:19 2013 by
577
+ Generated on Fri Feb 8 08:12:32 2013 by
578
578
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
579
- 0.8.3 (ruby-1.9.3).
579
+ 0.8.4.1 (ruby-1.9.3).
580
580
  </div>
581
581
 
582
582
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::Register
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -125,9 +125,9 @@
125
125
  </div>
126
126
 
127
127
  <div id="footer">
128
- Generated on Sat Feb 2 17:47:18 2013 by
128
+ Generated on Fri Feb 8 08:12:32 2013 by
129
129
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
130
- 0.8.3 (ruby-1.9.3).
130
+ 0.8.4.1 (ruby-1.9.3).
131
131
  </div>
132
132
 
133
133
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::BrowserMethods::Register::ClassMethods
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -1072,9 +1072,9 @@
1072
1072
  </div>
1073
1073
 
1074
1074
  <div id="footer">
1075
- Generated on Sat Feb 2 17:47:19 2013 by
1075
+ Generated on Fri Feb 8 08:12:32 2013 by
1076
1076
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1077
- 0.8.3 (ruby-1.9.3).
1077
+ 0.8.4.1 (ruby-1.9.3).
1078
1078
  </div>
1079
1079
 
1080
1080
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::Hooks
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -116,9 +116,9 @@
116
116
  </div>
117
117
 
118
118
  <div id="footer">
119
- Generated on Sat Feb 2 17:47:18 2013 by
119
+ Generated on Fri Feb 8 08:12:31 2013 by
120
120
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
121
- 0.8.3 (ruby-1.9.3).
121
+ 0.8.4.1 (ruby-1.9.3).
122
122
  </div>
123
123
 
124
124
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::Hooks::RubyOnRails
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -323,9 +323,9 @@
323
323
  </div>
324
324
 
325
325
  <div id="footer">
326
- Generated on Sat Feb 2 17:47:18 2013 by
326
+ Generated on Fri Feb 8 08:12:32 2013 by
327
327
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
328
- 0.8.3 (ruby-1.9.3).
328
+ 0.8.4.1 (ruby-1.9.3).
329
329
  </div>
330
330
 
331
331
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Brauser::Query
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -103,8 +103,9 @@
103
103
  <div class="discussion">
104
104
  <p>A query to a browser. This class enables concatenation, like:</p>
105
105
 
106
- <pre class="code ruby"><code><span class='const'>Brauser</span><span class='op'>::</span><span class='const'>Browser</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='period'>.</span><span class='id identifier rubyid_is'>is</span><span class='lparen'>(</span><span class='symbol'>:msie</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_v'>v</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>&gt;= 7</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_on?'>on?</span><span class='lparen'>(</span><span class='symbol'>:windows</span><span class='rparen'>)</span>
107
- </code></pre>
106
+ <p><code>ruby
107
+ Brauser::Browser.new.is(:msie).v("&gt;= 7").on?(:windows)
108
+ </code></p>
108
109
 
109
110
  <p>To end concatenation, use the <code>?</code> form of the queries or call <code>.result</code>.</p>
110
111
 
@@ -1724,9 +1725,9 @@
1724
1725
  </div>
1725
1726
 
1726
1727
  <div id="footer">
1727
- Generated on Sat Feb 2 17:47:19 2013 by
1728
+ Generated on Fri Feb 8 08:12:32 2013 by
1728
1729
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1729
- 0.8.3 (ruby-1.9.3).
1730
+ 0.8.4.1 (ruby-1.9.3).
1730
1731
  </div>
1731
1732
 
1732
1733
  </body>
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Module: Brauser::Version
8
8
 
9
- &mdash; Documentation by YARD 0.8.3
9
+ &mdash; Documentation by YARD 0.8.4.1
10
10
 
11
11
  </title>
12
12
 
@@ -149,7 +149,7 @@
149
149
 
150
150
  </div>
151
151
  </dt>
152
- <dd><pre class="code"><span class='int'>0</span></pre></dd>
152
+ <dd><pre class="code"><span class='int'>1</span></pre></dd>
153
153
 
154
154
  <dt id="STRING-constant" class="">STRING =
155
155
  <div class="docstring">
@@ -180,9 +180,9 @@
180
180
  </div>
181
181
 
182
182
  <div id="footer">
183
- Generated on Sat Feb 2 17:47:18 2013 by
183
+ Generated on Fri Feb 8 08:12:32 2013 by
184
184
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
185
- 0.8.3 (ruby-1.9.3).
185
+ 0.8.4.1 (ruby-1.9.3).
186
186
  </div>
187
187
 
188
188
  </body>