File: 0001-Fix-test-includes-for-Ruby-2.1.patch

package info (click to toggle)
ruby-bert 1.1.6-1
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 232 kB
  • ctags: 125
  • sloc: ruby: 805; ansic: 345; makefile: 2
file content (58 lines) | stat: -rw-r--r-- 1,676 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
From 9674150ba247cd3939c4fc119a452e5d5920dcf3 Mon Sep 17 00:00:00 2001
From: Balint Reczey <balint@balintreczey.hu>
Date: Mon, 8 Dec 2014 22:09:57 +0100
Subject: [PATCH 1/3] Fix test includes for Ruby 2.1

---
 test/bert_test.rb    | 2 +-
 test/decoder_test.rb | 2 +-
 test/encoder_test.rb | 2 +-
 test/test_helper.rb  | 1 +
 4 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/test/bert_test.rb b/test/bert_test.rb
index 10d3f46..dbc0324 100644
--- a/test/bert_test.rb
+++ b/test/bert_test.rb
@@ -1,4 +1,4 @@
-require 'test_helper'
+require File.dirname(__FILE__) + '/test_helper'
 
 class BertTest < Test::Unit::TestCase
   context "BERT" do
diff --git a/test/decoder_test.rb b/test/decoder_test.rb
index 3bbfee6..9f0cc02 100644
--- a/test/decoder_test.rb
+++ b/test/decoder_test.rb
@@ -1,4 +1,4 @@
-require 'test_helper'
+require File.dirname(__FILE__) + '/test_helper'
 
 class DecoderTest < Test::Unit::TestCase
   BERT_NIL = [131,104,2,100,0,4,98,101,114,116,100,0,3,110,105,108].pack('c*')
diff --git a/test/encoder_test.rb b/test/encoder_test.rb
index 75290a7..bb23d61 100644
--- a/test/encoder_test.rb
+++ b/test/encoder_test.rb
@@ -1,6 +1,6 @@
 # encoding: utf-8
 
-require 'test_helper'
+require File.dirname(__FILE__) + '/test_helper'
 
 class EncoderTest < Test::Unit::TestCase
   context "BERT Encoder complex type converter" do
diff --git a/test/test_helper.rb b/test/test_helper.rb
index d053e9a..cf2d7f9 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -1,5 +1,6 @@
 require 'rubygems'
 require 'test/unit'
+require 'minitest/autorun'
 require 'shoulda'
 
 $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
-- 
2.1.3