[DRE-commits] [ruby-simple-form] 04/04: skip tests that dependend on country_select

Antonio Terceiro terceiro at moszumanska.debian.org
Thu Nov 19 10:31:14 UTC 2015


This is an automated email from the git hooks/post-receive script.

terceiro pushed a commit to branch master
in repository ruby-simple-form.

commit 56f21559793435bf37db79d05dd65dc8f1d22659
Author: Antonio Terceiro <terceiro at debian.org>
Date:   Thu Nov 19 08:30:45 2015 -0200

    skip tests that dependend on country_select
---
 debian/changelog                                   |  2 +
 ...-Skip-tests-dependening-on-country_select.patch | 70 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 73 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index f79351d..2274866 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,7 @@
 ruby-simple-form (3.2.0-1) UNRELEASED; urgency=medium
 
   * Initial release (Closes: #nnnn)
+  * Added patch 0001-Skip-tests-dependening-on-country_select.patch to skip
+    tests that dependend on an optional dependency that is not in Debian yet.
 
  -- Antonio Terceiro <terceiro at debian.org>  Wed, 18 Nov 2015 16:25:22 -0200
diff --git a/debian/patches/0001-Skip-tests-dependening-on-country_select.patch b/debian/patches/0001-Skip-tests-dependening-on-country_select.patch
new file mode 100644
index 0000000..5b2e536
--- /dev/null
+++ b/debian/patches/0001-Skip-tests-dependening-on-country_select.patch
@@ -0,0 +1,70 @@
+From: Antonio Terceiro <terceiro at debian.org>
+Date: Thu, 19 Nov 2015 08:29:32 -0200
+Subject: Skip tests dependening on country_select
+
+---
+ test/form_builder/general_test.rb  | 1 +
+ test/inputs/priority_input_test.rb | 4 ++++
+ test/test_helper.rb                | 2 --
+ 3 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/test/form_builder/general_test.rb b/test/form_builder/general_test.rb
+index aa5f283..76d4dd4 100644
+--- a/test/form_builder/general_test.rb
++++ b/test/form_builder/general_test.rb
+@@ -148,6 +148,7 @@ class FormBuilderTest < ActionView::TestCase
+   end
+ 
+   test 'builder generates country fields for columns that matches country' do
++    skip 'country_select not in Debian yet'
+     with_form_for @user, :residence_country
+     assert_select 'form select#user_residence_country.country'
+   end
+diff --git a/test/inputs/priority_input_test.rb b/test/inputs/priority_input_test.rb
+index 3b8bbeb..bbf5bb8 100644
+--- a/test/inputs/priority_input_test.rb
++++ b/test/inputs/priority_input_test.rb
+@@ -3,6 +3,7 @@ require 'test_helper'
+ 
+ class PriorityInputTest < ActionView::TestCase
+   test 'input generates a country select field' do
++    skip 'country_select not in Debian yet'
+     with_input_for @user, :country, :country
+     assert_select 'select#user_country'
+     assert_select 'select option[value=Brazil]', 'Brazil'
+@@ -10,6 +11,7 @@ class PriorityInputTest < ActionView::TestCase
+   end
+ 
+   test 'input generates a country select with SimpleForm default' do
++    skip 'country_select not in Debian yet'
+     swap SimpleForm, country_priority: [ 'Brazil' ] do
+       with_input_for @user, :country, :country
+       assert_select 'select option[value=""][disabled=disabled]'
+@@ -36,12 +38,14 @@ class PriorityInputTest < ActionView::TestCase
+   end
+ 
+   test 'priority input does not generate invalid required html attribute' do
++    skip 'country_select not in Debian yet'
+     with_input_for @user, :country, :country
+     assert_select 'select.required'
+     assert_no_select 'select[required]'
+   end
+ 
+   test 'priority input does not generate invalid aria-required html attribute' do
++    skip 'country_select not in Debian yet'
+     with_input_for @user, :country, :country
+     assert_select 'select.required'
+     assert_no_select 'select[aria-required]'
+diff --git a/test/test_helper.rb b/test/test_helper.rb
+index cc41291..5e967e3 100644
+--- a/test/test_helper.rb
++++ b/test/test_helper.rb
+@@ -28,8 +28,6 @@ Dir["#{File.dirname(__FILE__)}/support/*.rb"].each do |file|
+ end
+ I18n.default_locale = :en
+ 
+-require 'country_select'
+-
+ if defined?(HTMLSelector::NO_STRIP)
+   HTMLSelector::NO_STRIP << "label"
+ else
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..5c193dd
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+0001-Skip-tests-dependening-on-country_select.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/ruby-simple-form.git



More information about the Pkg-ruby-extras-commits mailing list