Defect #31657
Update capybara (~> 3.25.0)
Status: | Closed | Start date: | ||
---|---|---|---|---|
Priority: | Normal | Due date: | ||
Assignee: | % Done: | 0% | ||
Category: | Gems support | |||
Target version: | 4.1.0 | |||
Resolution: | Fixed | Affected version: |
Description
I got the following warning while testing test/system.
This is caused by a version of capybara in Gemfile ('~> 2.13').
$ rake test TEST=test/system : WARN Selenium [DEPRECATION] Selenium::WebDriver::Error::UnhandledError is deprecated. Use Selenium::WebDriver::Error::UnknownError (ensure the driver supports W3C WebDriver specification) instead. WARN Selenium [DEPRECATION] Selenium::WebDriver::Error::ElementNotVisibleError is deprecated. Use Selenium::WebDriver::Error::ElementNotInteractableError (ensure the driver supports W3C WebDriver specification) instead. :
From the above, How about removing Capybara's version?
diff --git a/Gemfile b/Gemfile
index 37449f09f..3a5212e26 100644
--- a/Gemfile
+++ b/Gemfile
@@ -81,7 +81,7 @@ group :test do
gem "ffi", platforms: [:mingw, :x64_mingw, :mswin]
# For running system tests
gem 'puma', '~> 3.7'
- gem "capybara", '~> 2.13'
+ gem "capybara"
gem "selenium-webdriver"
# RuboCop
gem 'rubocop', '~> 0.72.0'
Related issues
Associated revisions
Update capybara (~> 3.25.0) (#31657).
Patch by Takenori TAKAKI and Pavel Rosický.
History
#1
Updated by Go MAEDA about 3 years ago
- Subject changed from DEPRECATION WARNING: Selenium::WebDriver::Error::***Error is deprecated. to Update capybara (~> 3.25.0)
- Category set to Gems support
- Target version set to 4.1.0
Thank you for reporting this issue.
I think it is better to pin the version to the tested one. Unintended update of gems may break test.
diff --git a/Gemfile b/Gemfile
index 37449f09f..9aa6e66f5 100644
--- a/Gemfile
+++ b/Gemfile
@@ -81,7 +81,7 @@ group :test do
gem "ffi", platforms: [:mingw, :x64_mingw, :mswin]
# For running system tests
gem 'puma', '~> 3.7'
- gem "capybara", '~> 2.13'
+ gem "capybara", '~> 3.25.0'
gem "selenium-webdriver"
# RuboCop
gem 'rubocop', '~> 0.72.0'
#2
Updated by Takenori TAKAKI about 3 years ago
- File 31657.patch
added
Thank you for your comment Mr. Maeda.
Go MAEDA wrote:
I think it is better to pin the version to the tested one. Unintended update of gems may break test.
I have the same opinion as you.
When I ran the test, I needed to fix the test code.
So I posted the patch again.
#3
Updated by Go MAEDA about 3 years ago
IssuesTest#test_issue_trackers_description_should_select_tracker randomly fails.
.........................[Screenshot]: tmp/screenshots/failures_test_issue_trackers_description_should_select_tracker.png F Failure: IssuesTest#test_issue_trackers_description_should_select_tracker [/Users/maeda/redmines/redmine-trunk/test/system/issues_test.rb:350]: Expected false to be truthy. bin/rails test test/system/issues_test.rb:344
#4
Updated by Pavel Rosický about 3 years ago
- File issues_test.rb.patch
added
Go MAEDA it fails because of scroll animations https://github.com/redmine/redmine/blob/master/public/javascripts/application.js#L28
#5
Updated by Go MAEDA about 3 years ago
Pavel Rosický wrote:
Go MAEDA it fails because of scroll animations https://github.com/redmine/redmine/blob/master/public/javascripts/application.js#L28
No errors are observed after applying your patch. Thanks.
#6
Updated by Go MAEDA about 3 years ago
- Subject changed from Update capybara (~> 3.25.0) to Update capybara (~> 3.15.1)
Capybara 3.25.0 cannot be used because Redmine 4.1.0 supports Ruby 2.3 but Capybara 3.25.0 does not. The last version of Capybara which supports Ruby 2.3 is 3.15.1.
#7
Updated by Go MAEDA about 3 years ago
- Subject changed from Update capybara (~> 3.15.1) to Update capybara (~> 3.25.0)
Index: Gemfile
===================================================================
--- Gemfile (revision 18329)
+++ Gemfile (working copy)
@@ -81,7 +81,7 @@
gem "ffi", platforms: [:mingw, :x64_mingw, :mswin]
# For running system tests
gem 'puma', '~> 3.7'
- gem "capybara", '~> 2.13'
+ gem "capybara", (RUBY_VERSION < "2.4" ? "~> 3.15.1" : "~> 3.25.0")
gem "selenium-webdriver"
# RuboCop
gem 'rubocop', '~> 0.72.0'
#8
Updated by Go MAEDA about 3 years ago
- Status changed from New to Closed
- Assignee set to Go MAEDA
- Resolution set to Fixed
Committed the patch. Thank you.
#9
Updated by Takenori TAKAKI over 2 years ago
- Status changed from Closed to Reopened
The latest version of Capybara (3.29.0) has been released, so I updated the gem and re-tested the "test/system".
And I confirmed that all tests passed.
index 587bdb101..1d7c8fe1c 100644
--- a/Gemfile
+++ b/Gemfile
@@ -81,7 +81,7 @@ group :test do
gem "ffi", platforms: [:mingw, :x64_mingw, :mswin]
# For running system tests
gem 'puma', '~> 3.7'
- gem "capybara", (RUBY_VERSION < "2.4" ? "~> 3.15.1" : "~> 3.25.0")
+ gem "capybara", (RUBY_VERSION < "2.4" ? "~> 3.15.1" : "~> 3.29.0")
gem "selenium-webdriver"
# RuboCop
gem 'rubocop', '~> 0.76.0'
#10
Updated by Go MAEDA over 2 years ago
- Copied to Patch #32453: Update capybara (~> 3.31.0) added
#11
Updated by Go MAEDA over 2 years ago
- Status changed from Reopened to Closed
Takenori TAKAKI wrote:
The latest version of Capybara (3.29.0) has been released, so I updated the gem and re-tested the "test/system".
And I confirmed that all tests passed.
Thank you for testing the latest version of Capybara. But 4.1-stable branch has been created and Redmine 4.1.0 is about to be released, so I have opened a new issue #32453 for Redmine 4.2.0.