You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by sh...@apache.org on 2019/06/17 10:43:54 UTC

[arrow] branch master updated: ARROW-5447: [Ruby] Ensure flushing test gz file

This is an automated email from the ASF dual-hosted git repository.

shiro pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git


The following commit(s) were added to refs/heads/master by this push:
     new 9425831  ARROW-5447: [Ruby] Ensure flushing test gz file
9425831 is described below

commit 9425831dfaf854b5f6e26af1b23afe60f883af74
Author: Sutou Kouhei <ko...@clear-code.com>
AuthorDate: Mon Jun 17 19:43:40 2019 +0900

    ARROW-5447: [Ruby] Ensure flushing test gz file
    
    Author: Sutou Kouhei <ko...@clear-code.com>
    
    Closes #4584 from kou/ruby-test-robust and squashes the following commits:
    
    c1bdcaefe <Sutou Kouhei> Run MinGW build when Ruby codes are changed
    dc498bd49 <Sutou Kouhei>  Ensure flushing test gz file
---
 appveyor.yml                      | 3 ++-
 ci/appveyor-filter-changes.bat    | 6 +++---
 ruby/red-arrow/test/test-table.rb | 5 +++--
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/appveyor.yml b/appveyor.yml
index 3e0e645..cefa28e 100644
--- a/appveyor.yml
+++ b/appveyor.yml
@@ -19,7 +19,7 @@
 os: Visual Studio 2015
 
 only_commits:
-  # Skip commits not related to Python, C++, C#, Go or Rust
+  # Skip commits not related to Python, C++, C#, Go, Ruby or Rust
   files:
     - appveyor.yml
     - c_glib/
@@ -29,6 +29,7 @@ only_commits:
     - format/
     - go/
     - python/
+    - ruby/
     - rust/
 
 cache:
diff --git a/ci/appveyor-filter-changes.bat b/ci/appveyor-filter-changes.bat
index 1e82ecd..04da517 100644
--- a/ci/appveyor-filter-changes.bat
+++ b/ci/appveyor-filter-changes.bat
@@ -22,10 +22,10 @@ if "%JOB%" == "Rust" (
         echo ===
         appveyor exit
     )
-) else if "%JOB%" == "MinGW" (
-    if "%ARROW_CI_GLIB_AFFECTED%" == "0" (
+) else if "%JOB:~,5%" == "MinGW" (
+    if "%ARROW_CI_RUBY_AFFECTED%" == "0" (
         echo ===
-        echo === No C++, or GLib changes, exiting job
+        echo === No C++, GLib or Ruby changes, exiting job
         echo ===
         appveyor exit
     )
diff --git a/ruby/red-arrow/test/test-table.rb b/ruby/red-arrow/test/test-table.rb
index 6af2b57..2b7a46c 100644
--- a/ruby/red-arrow/test/test-table.rb
+++ b/ruby/red-arrow/test/test-table.rb
@@ -492,7 +492,8 @@ class TableTest < Test::Unit::TestCase
 
           test("csv.gz") do
             file = Tempfile.new(["red-arrow", ".csv.gz"])
-            Zlib::GzipWriter.wrap(file) do |gz|
+            file.close
+            Zlib::GzipWriter.open(file.path) do |gz|
               gz.write(<<-CSV)
 name,score
 alice,10
@@ -505,7 +506,7 @@ chris,-1
 0	alice	   10
 1	bob 	   29
 2	chris	   -1
-          TABLE
+            TABLE
           end
         end
       end