lapis_lazuli 2.1.4 → 2.2.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
- SHA1:
3
- metadata.gz: ae4a283fea52d6ece979ec5d13f56dd66a776273
4
- data.tar.gz: f9e1efb4ae1d6f1330562c255f1017bc47139c62
2
+ SHA256:
3
+ metadata.gz: 7279ab7a63b500202b0bcf3eaa9f1290fd91426f4752f0962e37a0a1d46d0d21
4
+ data.tar.gz: e8716670e00490626a1f9fedd1a4413d907c444c813f82813d9613e21df23cd4
5
5
  SHA512:
6
- metadata.gz: ebf4e8e6b70bba8ef27c719ee072ae3ea9440c74b6fc3ba3fd9924a96d8a235996125e400b5c42252a27bbe93f9742eaa9dfd0d7137c838a5d506b881290e48f
7
- data.tar.gz: 5ce631215fc80b0995f30299cc6aa1a77635b8504e48c2108a666fa11792f756060f592a8b9c3fd3177a583c67d7c3c283e1b8e9db98f388d7bdc2fedb705a26
6
+ metadata.gz: 93eb7a33d126bd721fa8ae7430f416c3824ec40b6e0661136905fa59a98e6c23dfdf083d4544511f20adacc978c9633dae24e346683c8f54a84eb4cfaa301051
7
+ data.tar.gz: fd4c7d0409848a0ca9b558f7684036c3e1df099e06075f479e37f4f4b9f5d05e3aaaeeaa0a820eb1b0d7190dc43aee2f7d3bea96103a381894f300b532d2f742
data/README.md CHANGED
@@ -77,4 +77,4 @@ further documentation.
77
77
  Please see [the Wiki page on contributing](https://github.com/spriteCloud/lapis-lazuli/wiki/Contributing)
78
78
 
79
79
  ## License
80
- Copyright (c) 2013-2017 spriteCloud B.V. and other node-apinator contributors. See [the LICENSE file](LICENSE) for details.
80
+ Copyright (c) 2013-2019 spriteCloud B.V. and other node-apinator contributors. See [the LICENSE file](LICENSE) for details.
@@ -31,22 +31,23 @@ Gem::Specification.new do |spec|
31
31
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
32
32
  spec.require_paths = ["lib"]
33
33
 
34
- spec.add_development_dependency "bundler", "~> 1.6"
35
- spec.add_development_dependency "rake", "~> 12.0"
36
- spec.add_development_dependency "simplecov", "~> 0.12"
34
+ spec.add_development_dependency "bundler", "~> 2.0"
35
+ spec.add_development_dependency "rake", "~> 12.3"
36
+ spec.add_development_dependency "simplecov", "~> 0.17"
37
37
 
38
- spec.add_dependency "faraday_middleware", "~> 0.10"
38
+ spec.add_dependency "faraday_middleware", "~> 0.13"
39
39
  spec.add_dependency "faraday_json", "~> 0.1"
40
40
  spec.add_dependency "multi_xml", "~> 0.6"
41
41
  spec.add_dependency "teelogger", "~> 0.5"
42
- spec.add_dependency "minitest", "~> 5.10"
43
- spec.add_dependency "thor", "~> 0.19" # Used in the cucumber project generator
42
+ spec.add_dependency "minitest", "~> 5.11"
43
+ spec.add_dependency "thor", "~> 0.20" # Used in the cucumber project generator
44
44
  spec.add_dependency "facets", "~> 3.1" # Used in the cucumber project generator
45
45
  spec.add_dependency "deep_merge", "~> 1.2"
46
46
 
47
47
  # webdriver specifics
48
48
  spec.add_dependency "selenium-webdriver", ">= 2.0", '< 4'
49
49
  spec.add_dependency "watir", "~> 6"
50
+ spec.add_dependency "ffi", "~> 1.11"
50
51
  spec.add_dependency "cucumber", ">= 2.0", '< 4.0'
51
52
 
52
53
  end
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  require 'thor'
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -42,6 +42,6 @@ production:
42
42
  about-us: /about-us/
43
43
  testing: /testing/
44
44
  blog: /blog/
45
- functional-testing: /testing/functional/
45
+ functional-testing: /testing/functional-testing/
46
46
  jobs: /jobs
47
47
  training-page: http://training-page.testautomation.info/#
@@ -11,13 +11,20 @@ I want to run and adjust the tests below
11
11
  Then text "Open Source" should display somewhere on the page
12
12
 
13
13
  @basic_02
14
- Scenario: example02 - Going to a search result
15
- Given the user navigates to "https://spritecloud.com/?s=lapis+lazuli"
16
- When the user clicks on link "/announcing-lapislazuli/"
17
- Then text "Let's talk about testing" should display somewhere on the page
14
+ Scenario: example02 - scrolling down
15
+ Given the user navigates to "home"
16
+ When the user scrolls down
17
+ Then text "Project-based services are typically short-term" should display somewhere on the page
18
18
 
19
19
  @basic_03
20
- Scenario Outline: example03 - checking multiple pages for the logo
20
+ Scenario: example03 - Going to a search result
21
+ Given the user navigates to "https://www.spritecloud.com/?s=lapis+lazuli"
22
+ When the user scrolls down
23
+ And the user clicks on link "/announcing-lapislazuli/"
24
+ Then text "A few days later you are working" should display somewhere on the page
25
+
26
+ @basic_04
27
+ Scenario Outline: example04 - checking multiple pages for the logo
21
28
  Given the user navigates to "<page>"
22
29
  When the user clicks on the spritecloud logo
23
30
  Then the user should be on page "home"
@@ -35,8 +42,8 @@ I want to run and adjust the tests below
35
42
  # or, if you want to test it on a specific environment:
36
43
  # bundle exec cucumber -p production -p debug -t @basic_04
37
44
  # Good luck fixing the problems!
38
- @basic_04 @dev
39
- Scenario: example_04 - confirming there is a no results page
45
+ @basic_05 @dev
46
+ Scenario: example_05 - confirming there is a no results page
40
47
  Given the user navigates to "blog"
41
48
  When the user searches for "no_results_expected"
42
49
  Then the text "Nothing Found" should display on the blog page
@@ -104,8 +104,8 @@ module Auth
104
104
  # If user=nil, we expect that there already is user data loaded in a previous step.
105
105
  User.load_user_data(user) unless user.nil?
106
106
 
107
- Auth.username_field.to_subtype.set(User.get('username'))
108
- Auth.password_field.to_subtype.set(User.get('password'))
107
+ Auth.username_field.to_subtype.to_subtype.set(User.get('username'))
108
+ Auth.password_field.to_subtype.to_subtype.set(User.get('password'))
109
109
  Auth.login_button.click
110
110
 
111
111
  unless Auth.is_logged_in? user
@@ -114,7 +114,7 @@ module Auth
114
114
  error "Failed to log in user #{user}"
115
115
  else
116
116
  alert.flash
117
- error "Found error while logging in #{user}: `#{alert.text}`"
117
+ error "Found error while logging in #{user}: `#{alert.html}`"
118
118
  end
119
119
  end
120
120
  end
@@ -8,7 +8,7 @@ module Register
8
8
  # @formatter:off
9
9
  def form; browser.wait(:like => [:form, :id, 'form-register']); end
10
10
  def open_register_button; browser.find(:like => [:button, :id, 'button-register']); end
11
- def username_field; browser.find(:element => {:name => 'username'}, :context => Register.form); end
11
+ def username_field; browser.wait(:element => {:name => 'username'}, :context => Register.form); end
12
12
  def password_field; browser.find(:element => {:name => 'password'}, :context => Register.form); end
13
13
  def experience_field; browser.find(:like => [:select, :id, "register-experience"], :context => form); end
14
14
  def biography_field; browser.find(:like => [:textarea, :id, 'register-bio']); end
@@ -52,16 +52,25 @@ module Register
52
52
  end
53
53
 
54
54
  def fill_form
55
- Register.username_field.set(User.get('username'))
56
- Register.password_field.set(User.get('password'))
55
+ #the setter goes too fast sometimes not finishing the username, this will re-set the username when it does
56
+ browser.wait_until(timeout: 10, message: 'False did not become true withing 10 seconds') {
57
+ Register.username_field.to_subtype.set(User.get('username'))
58
+ Register.username_field.value == User.get('username')
59
+ }
60
+ Register.username_field.to_subtype.set(User.get('username'))
61
+ Register.password_field.to_subtype.set(User.get('password'))
57
62
  Register.gender_radio(User.get('gender')).click
58
63
  Register.select_experiences(User.get('experience').split(','))
59
- Register.biography_field.set(User.get('biography'))
60
- Register.policy_checkbox.set((User.get('complete_all').to_i == 1))
64
+ Register.biography_field.to_subtype.set(User.get('biography'))
65
+ Register.policy_checkbox.to_subtype.set((User.get('complete_all').to_i == 1))
61
66
  end
62
67
 
63
68
  def submit_form
64
69
  Register.submit_button.click
70
+ browser.wait(
71
+ :like => [:div, :class, 'modal-backdrop fade in'],
72
+ :condition => :while
73
+ )
65
74
  end
66
75
 
67
76
  def register_user
@@ -73,8 +82,8 @@ module Register
73
82
  alert = browser.wait(like: [:div, :class, 'alert'], timeout: 2, throw: false)
74
83
  if alert.nil?
75
84
  return false, 'No message was displayed after registering'
76
- elsif !alert.text.include? User.get('username')
77
- return false, "An error message did display, but didn't contain the expected text: `#{alert.text}`"
85
+ elsif !alert.html.include? User.get('username')
86
+ return false, "An error message did display, but didn't contain the expected text: `#{alert.html}`"
78
87
  end
79
88
  return true, 'Successfully found the success message'
80
89
  end
@@ -25,6 +25,10 @@ Given(/^the user searches for "(.*?)"$/) do |query|
25
25
  searchbox.send_keys(:enter)
26
26
  end
27
27
 
28
+ When(/^the user scrolls down$/) do
29
+ browser.driver.execute_script("window.scrollBy(0,400)")
30
+ end
31
+
28
32
  Then(/^text "([^"]*)" should display somewhere on the page$/) do |string|
29
33
  # Search for the text on the page
30
34
  browser.wait(:xpath => "//*[contains(text(),\"#{string}\")]")
@@ -32,6 +36,7 @@ end
32
36
 
33
37
  When(/^the user clicks on link "(.*?)"$/) do |url|
34
38
  # Search for the element that includes the expected text
39
+
35
40
  browser.wait(
36
41
  :like => {
37
42
  :element => :a,
@@ -44,8 +49,8 @@ end
44
49
  When(/^the user clicks on the spritecloud logo$/) do
45
50
  # Search for the logo
46
51
  logo = browser.find(
47
- :like => [:img, :id, 'logo'],
48
- :message => 'Unable to find the logo on this page.'
52
+ a: {class: ['logo']},
53
+ message: 'Unable to find the logo on this page.'
49
54
  )
50
55
  # And click the logo
51
56
  logo.click
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  module LapisLazuli
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  module LapisLazuli
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  #
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
 
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  require 'singleton'
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  require "securerandom"
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  module LapisLazuli
@@ -2,9 +2,9 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  module LapisLazuli
9
- VERSION = "2.1.4"
9
+ VERSION = "2.2.0"
10
10
  end
@@ -2,7 +2,7 @@
2
2
  # LapisLazuli
3
3
  # https://github.com/spriteCloud/lapis-lazuli
4
4
  #
5
- # Copyright (c) 2013-2017 spriteCloud B.V. and other LapisLazuli contributors.
5
+ # Copyright (c) 2013-2019 spriteCloud B.V. and other LapisLazuli contributors.
6
6
  # All rights reserved.
7
7
  #
8
8
  require 'lapis_lazuli/api'
@@ -4,7 +4,6 @@
4
4
  # Author: "spriteCloud" <info@spritecloud.com>
5
5
  require 'lapis_lazuli'
6
6
  require 'lapis_lazuli/cucumber'
7
- require 'cucumber/calliope_importer'
8
7
 
9
8
  module TestModule
10
9
  def test_func
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lapis_lazuli
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.4
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Onno Steenbergen
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2018-08-08 00:00:00.000000000 Z
14
+ date: 2019-09-18 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: bundler
@@ -19,56 +19,56 @@ dependencies:
19
19
  requirements:
20
20
  - - "~>"
21
21
  - !ruby/object:Gem::Version
22
- version: '1.6'
22
+ version: '2.0'
23
23
  type: :development
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - "~>"
28
28
  - !ruby/object:Gem::Version
29
- version: '1.6'
29
+ version: '2.0'
30
30
  - !ruby/object:Gem::Dependency
31
31
  name: rake
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  requirements:
34
34
  - - "~>"
35
35
  - !ruby/object:Gem::Version
36
- version: '12.0'
36
+ version: '12.3'
37
37
  type: :development
38
38
  prerelease: false
39
39
  version_requirements: !ruby/object:Gem::Requirement
40
40
  requirements:
41
41
  - - "~>"
42
42
  - !ruby/object:Gem::Version
43
- version: '12.0'
43
+ version: '12.3'
44
44
  - !ruby/object:Gem::Dependency
45
45
  name: simplecov
46
46
  requirement: !ruby/object:Gem::Requirement
47
47
  requirements:
48
48
  - - "~>"
49
49
  - !ruby/object:Gem::Version
50
- version: '0.12'
50
+ version: '0.17'
51
51
  type: :development
52
52
  prerelease: false
53
53
  version_requirements: !ruby/object:Gem::Requirement
54
54
  requirements:
55
55
  - - "~>"
56
56
  - !ruby/object:Gem::Version
57
- version: '0.12'
57
+ version: '0.17'
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: faraday_middleware
60
60
  requirement: !ruby/object:Gem::Requirement
61
61
  requirements:
62
62
  - - "~>"
63
63
  - !ruby/object:Gem::Version
64
- version: '0.10'
64
+ version: '0.13'
65
65
  type: :runtime
66
66
  prerelease: false
67
67
  version_requirements: !ruby/object:Gem::Requirement
68
68
  requirements:
69
69
  - - "~>"
70
70
  - !ruby/object:Gem::Version
71
- version: '0.10'
71
+ version: '0.13'
72
72
  - !ruby/object:Gem::Dependency
73
73
  name: faraday_json
74
74
  requirement: !ruby/object:Gem::Requirement
@@ -117,28 +117,28 @@ dependencies:
117
117
  requirements:
118
118
  - - "~>"
119
119
  - !ruby/object:Gem::Version
120
- version: '5.10'
120
+ version: '5.11'
121
121
  type: :runtime
122
122
  prerelease: false
123
123
  version_requirements: !ruby/object:Gem::Requirement
124
124
  requirements:
125
125
  - - "~>"
126
126
  - !ruby/object:Gem::Version
127
- version: '5.10'
127
+ version: '5.11'
128
128
  - !ruby/object:Gem::Dependency
129
129
  name: thor
130
130
  requirement: !ruby/object:Gem::Requirement
131
131
  requirements:
132
132
  - - "~>"
133
133
  - !ruby/object:Gem::Version
134
- version: '0.19'
134
+ version: '0.20'
135
135
  type: :runtime
136
136
  prerelease: false
137
137
  version_requirements: !ruby/object:Gem::Requirement
138
138
  requirements:
139
139
  - - "~>"
140
140
  - !ruby/object:Gem::Version
141
- version: '0.19'
141
+ version: '0.20'
142
142
  - !ruby/object:Gem::Dependency
143
143
  name: facets
144
144
  requirement: !ruby/object:Gem::Requirement
@@ -201,6 +201,20 @@ dependencies:
201
201
  - - "~>"
202
202
  - !ruby/object:Gem::Version
203
203
  version: '6'
204
+ - !ruby/object:Gem::Dependency
205
+ name: ffi
206
+ requirement: !ruby/object:Gem::Requirement
207
+ requirements:
208
+ - - "~>"
209
+ - !ruby/object:Gem::Version
210
+ version: '1.11'
211
+ type: :runtime
212
+ prerelease: false
213
+ version_requirements: !ruby/object:Gem::Requirement
214
+ requirements:
215
+ - - "~>"
216
+ - !ruby/object:Gem::Version
217
+ version: '1.11'
204
218
  - !ruby/object:Gem::Dependency
205
219
  name: cucumber
206
220
  requirement: !ruby/object:Gem::Requirement
@@ -348,7 +362,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
348
362
  version: '0'
349
363
  requirements: []
350
364
  rubyforge_project:
351
- rubygems_version: 2.6.14
365
+ rubygems_version: 2.7.6
352
366
  signing_key:
353
367
  specification_version: 4
354
368
  summary: Cucumber helper functions and scaffolding for easier test automation suite