[DRE-commits] [ruby-sshkit] 06/07: Disable formatting tests (require ruby-turn, not yet packaged)

Sebastien Badia sbadia-guest at moszumanska.debian.org
Mon May 4 15:48:45 UTC 2015


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

sbadia-guest pushed a commit to branch master
in repository ruby-sshkit.

commit a462e64226dbf2cb6efab641763b08dcf0a67ed3
Author: Sebastien Badia <seb at sebian.fr>
Date:   Mon May 4 15:15:34 2015 +0200

    Disable formatting tests (require ruby-turn, not yet packaged)
---
 debian/changelog                                   |  1 +
 debian/patches/001_disabled-rubygems-bundler.patch |  3 +-
 .../003_disabled-tests-that-require-turn.patch     | 82 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 debian/ruby-tests.rake                             |  2 +-
 5 files changed, 87 insertions(+), 2 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 7bddc69..e277276 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
 ruby-sshkit (1.7.1-1) UNRELEASED; urgency=medium
 
   * New upstream release.
+  * Fix Build-Depends (add minitest instead of rspec).
   * Update Vcs-Browser to cgit URL and HTTPS.
   * Bump Standards-Version to 3.9.6 (no further changes).
 
diff --git a/debian/patches/001_disabled-rubygems-bundler.patch b/debian/patches/001_disabled-rubygems-bundler.patch
index ae7f90a..b1e1f8f 100644
--- a/debian/patches/001_disabled-rubygems-bundler.patch
+++ b/debian/patches/001_disabled-rubygems-bundler.patch
@@ -12,7 +12,8 @@ Last-Update: 2014-04-21
 -require 'rubygems'
 -require 'bundler/setup'
  require 'tempfile'
- require 'minitest/unit'
+-require 'minitest/unit'
++require 'minitest/autorun'
  require 'mocha/setup'
 -require 'turn'
 -require 'unindent'
diff --git a/debian/patches/003_disabled-tests-that-require-turn.patch b/debian/patches/003_disabled-tests-that-require-turn.patch
new file mode 100644
index 0000000..be09fe3
--- /dev/null
+++ b/debian/patches/003_disabled-tests-that-require-turn.patch
@@ -0,0 +1,82 @@
+Description: Disable tests that require turn.
+ Turn is not yet packaged.
+Author: Sebastien Badia <seb at sebian.fr>
+Forwarded: not-needed
+Last-Update: 2015-05-04
+
+--- ruby-sshkit-1.7.1.orig/test/unit/formatters/test_dot.rb
++++ ruby-sshkit-1.7.1/test/unit/formatters/test_dot.rb
+@@ -47,19 +47,5 @@ module SSHKit
+       assert_equal "", output.strip
+     end
+ 
+-    def test_command_success
+-      command = SSHKit::Command.new(:ls)
+-      command.exit_status = 0
+-      dot << command
+-      assert_equal "\e[0;32;49m.\e[0m", output.strip
+-    end
+-
+-    def test_command_failure
+-      command = SSHKit::Command.new(:ls, {raise_on_non_zero_exit: false})
+-      command.exit_status = 1
+-      dot << command
+-      assert_equal "\e[0;31;49m.\e[0m", output.strip
+-    end
+-
+   end
+ end
+--- ruby-sshkit-1.7.1.orig/test/unit/formatters/test_pretty.rb
++++ /dev/null
+@@ -1,51 +0,0 @@
+-require 'helper'
+-require 'sshkit'
+-
+-module SSHKit
+-  class TestPretty < UnitTest
+-
+-    def setup
+-      SSHKit.config.output_verbosity = Logger::DEBUG
+-    end
+-
+-    def output
+-      @_output ||= String.new
+-    end
+-
+-    def pretty
+-      @_pretty ||= SSHKit::Formatter::Pretty.new(output)
+-    end
+-
+-    def teardown
+-      remove_instance_variable :@_pretty
+-      remove_instance_variable :@_output
+-      SSHKit.reset_configuration!
+-    end
+-
+-    def test_logging_fatal
+-      pretty << SSHKit::LogMessage.new(Logger::FATAL, "Test")
+-      assert_equal output.strip, "\e[0;31;49mFATAL\e[0m Test"
+-    end
+-
+-    def test_logging_error
+-      pretty << SSHKit::LogMessage.new(Logger::ERROR, "Test")
+-      assert_equal output.strip, "\e[0;31;49mERROR\e[0m Test"
+-    end
+-
+-    def test_logging_warn
+-      pretty << SSHKit::LogMessage.new(Logger::WARN, "Test")
+-      assert_equal output.strip, "\e[0;33;49mWARN\e[0m Test".strip
+-    end
+-
+-    def test_logging_info
+-      pretty << SSHKit::LogMessage.new(Logger::INFO, "Test")
+-      assert_equal output.strip, "\e[0;34;49mINFO\e[0m Test".strip
+-    end
+-
+-    def test_logging_debug
+-      pretty << SSHKit::LogMessage.new(Logger::DEBUG, "Test")
+-      assert_equal output.strip, "\e[0;30;49mDEBUG\e[0m Test".strip
+-    end
+-
+-  end
+-end
diff --git a/debian/patches/series b/debian/patches/series
index 6904525..c7ad5e5 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
 001_disabled-rubygems-bundler.patch
 002_fix-local-test-cd.patch
+003_disabled-tests-that-require-turn.patch
diff --git a/debian/ruby-tests.rake b/debian/ruby-tests.rake
index 80aafe6..5c06684 100644
--- a/debian/ruby-tests.rake
+++ b/debian/ruby-tests.rake
@@ -1,6 +1,6 @@
 require 'rake/testtask'
 task :default => :test
-Rake::TestTask.new do |t| 
+Rake::TestTask.new do |t|
   t.libs << 'test'
   t.test_files = FileList['test/unit/**/test*.rb']
   t.verbose = true

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



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