gless 2.1.1 → 3.0.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e4550c784a5681ac3c6c901717552c84bb73cf65
4
- data.tar.gz: adf62a9f927189b9592e29dd0cdbcb6502b01eac
3
+ metadata.gz: a344cb58f7d46bdfbbb4a6e0c6b2308864ac45db
4
+ data.tar.gz: 6a7291b27b4ee4d0269aebf1158bc43f32e77a0d
5
5
  SHA512:
6
- metadata.gz: a3dfdc73d9389a1ea10cda7e60dbb56bc7c0b67ba5a5c8b5a09153dd555cb9e942d684028209f0630fc45a082ccfca15e13be13471850443822ec21c29d7bbb7
7
- data.tar.gz: 279b96b2666264d123100f0d9beccb2261f061afff0b4ecfe43a1a46141c75f5909832c974dede0489b75a7a50d87cf20d719d04e7c82bf24e46dbcef06cc1d5
6
+ metadata.gz: b52365c895256bc6f53b60b88d10433db3c1786a6a1d95aa37198d7a5cc0c5f6e7f61d30f9aaa3727a695a6273a24f7b543b46a1397015cfd3f228ccc0a6a9ca
7
+ data.tar.gz: 5618ab7947d2671bd684dd83c6985fe244ba049133b8840270a80e1a49f5fdeda06504d1282c85a55ca07703d4c3acb0c2a6ca699ecce2be9e922948df245d25
data/Changelog.txt CHANGED
@@ -29,3 +29,4 @@
29
29
  - 2.1.1: 31 Jul 2014: Major changes to what happenes when we fail to
30
30
  arrive at a page; eventually the exception should trickle
31
31
  up to the user.
32
+ - 3.0.0: 28 Oct 2014: Converted to RSpec 3
data/README.md CHANGED
@@ -180,7 +180,7 @@ module TestGithub
180
180
 
181
181
  @session = Gless::Session.new( @browser, @config, @logger, self )
182
182
 
183
- @session.should be_true
183
+ @session.should be_truthy
184
184
  end
185
185
  end
186
186
  ```
@@ -1,7 +1,7 @@
1
1
  Given %r{^I start the application$} do
2
2
  klass = @config.get :global, :site, :class
3
3
  @application = Object.const_get(klass)::Application.new( @browser, @config, @logger )
4
- @application.should be_true
4
+ @application.should be_truthy
5
5
  end
6
6
 
7
7
  When %r{^I fall through to the page object$} do
@@ -17,7 +17,7 @@ When 'I poke lots of buttons' do
17
17
  end
18
18
 
19
19
  Then 'I am on the Gless repo page' do
20
- @application.session.arrived?.should be_true
20
+ @application.session.arrived?.should be_truthy
21
21
  @application.browser.url.should == 'https://github.com/rlpowell/gless'
22
22
  end
23
23
 
@@ -20,12 +20,12 @@ module TestGithub
20
20
  @config = config
21
21
 
22
22
  @base_url = @config.get :global, :site, :url
23
- @base_url.should be_true
23
+ @base_url.should be_truthy
24
24
 
25
25
  # Create the session
26
26
  @session = Gless::Session.new( @browser, @config, @logger, self )
27
27
 
28
- @session.should be_true
28
+ @session.should be_truthy
29
29
 
30
30
  @logger.info "TestGithub Application: going to github"
31
31
  @session.enter TestGithub::LoginPage
@@ -39,7 +39,7 @@ module TestGithub
39
39
  @session.search_for name
40
40
 
41
41
  repodata = @session.find_repository repo_pattern
42
- repodata.should be_true, "TestGithub Application: couldn't find repository #{name}"
42
+ repodata.should be_truthy, "TestGithub Application: couldn't find repository #{name}"
43
43
 
44
44
  @logger.info "TestGithub Application: found repository #{repodata[:name]}, which was at number #{repodata[:index] + 1} on the page, now opening it."
45
45
 
data/lib/gless.rb CHANGED
@@ -6,7 +6,7 @@
6
6
  # project.
7
7
  module Gless
8
8
  # The current version number.
9
- VERSION = '2.1.1'
9
+ VERSION = '3.0.0'
10
10
 
11
11
  # Sets up the config, logger and browser instances, the ordering
12
12
  # of which is slightly tricky. If a block is given, the config, after being
@@ -39,7 +39,7 @@ module Gless
39
39
  ::RSpec.configure do |config|
40
40
  # RSpec automatically cleans stuff out of backtraces;
41
41
  # sometimes this is annoying when trying to debug something e.g. a gem
42
- config.backtrace_clean_patterns = []
42
+ config.backtrace_exclusion_patterns = []
43
43
  end
44
44
  end
45
45
 
@@ -448,15 +448,15 @@ module Gless
448
448
 
449
449
  begin
450
450
  if respond_to? :has_expected_title?
451
- has_expected_title?.should be_true
451
+ has_expected_title?.should be_truthy
452
452
  end
453
453
 
454
- match_url( @browser.url ).should be_true
454
+ match_url( @browser.url ).should be_truthy
455
455
 
456
456
  # We don't use all_validate here because we want to alert on the
457
457
  # element with the problem
458
458
  self.class.validator_elements.each do |x|
459
- self.send(x).wait_until_present(5).should be_true
459
+ self.send(x).wait_until_present(5).should be_truthy
460
460
  end
461
461
 
462
462
  @session.log.debug "In GenericBasePage, for #{self.class.name}, arrived?: completed successfully."
data/lib/gless/session.rb CHANGED
@@ -138,11 +138,11 @@ module Gless
138
138
  end
139
139
  end
140
140
 
141
- good_page.should be_true, "Current URL is #{@browser.url}, which doesn't match any of the acceptable pages: #{@acceptable_pages}"
141
+ good_page.should be_truthy, "Current URL is #{@browser.url}, which doesn't match any of the acceptable pages: #{@acceptable_pages}"
142
142
 
143
143
  url=@browser.url
144
144
  log.debug "Session: refreshed browser URL: #{url}"
145
- new_page.match_url(url).should be_true
145
+ new_page.match_url(url).should be_truthy
146
146
 
147
147
  log.info "Session: We are currently on page #{new_page.class.name}, as we should be"
148
148
 
@@ -416,7 +416,7 @@ module Gless
416
416
  if @click_destination && change_pages
417
417
  @session.log.debug "WrapWatir: #{@name}.click_once: changing pages"
418
418
  change_pages_out, change_pages_message = @session.change_pages @click_destination, &block
419
- change_pages_out.should be_true, change_pages_message
419
+ change_pages_out.should be_truthy, change_pages_message
420
420
  end
421
421
  end
422
422
 
@@ -455,7 +455,7 @@ module Gless
455
455
  # If the return value isn't true, use it as the message to
456
456
  # print.
457
457
  @session.log.debug "WrapWatir: click: change pages results: #{change_pages_out}, #{change_pages_message}"
458
- change_pages_out.should be_true, change_pages_message
458
+ change_pages_out.should be_truthy, change_pages_message
459
459
  else
460
460
  wrapper_logging('click', nil)
461
461
  @session.log.debug "WrapWatir: click: Calling click on a #{elem.class.name} element identified by: #{trimmed_selectors.inspect}"
@@ -527,7 +527,7 @@ module Gless
527
527
  wrap_watir_call :set
528
528
  end
529
529
  end
530
- wrap_watir_call(:set?).should be_true
530
+ wrap_watir_call(:set?).should be_truthy
531
531
  @session.log.debug "WrapWatir: The radio set worked"
532
532
 
533
533
  return self
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gless
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.1
4
+ version: 3.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robin Lee Powell
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-07-31 00:00:00.000000000 Z
12
+ date: 2014-10-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rspec