[前][次][番号順一覧][スレッド一覧]

ruby-changes:60971

From: Nobuyoshi <ko1@a...>
Date: Fri, 1 May 2020 19:53:39 +0900 (JST)
Subject: [ruby-changes:60971] 28aa5f7fa6 (master): Fixed a message and version guard then moved to the existing block

https://git.ruby-lang.org/ruby.git/commit/?id=28aa5f7fa6

From 28aa5f7fa6d7a37de6a4c348f19cf0a595cc2553 Mon Sep 17 00:00:00 2001
From: Nobuyoshi Nakada <nobu@r...>
Date: Fri, 1 May 2020 19:34:24 +0900
Subject: Fixed a message and version guard then moved to the existing block


diff --git a/spec/ruby/library/matrix/unitary_spec.rb b/spec/ruby/library/matrix/unitary_spec.rb
index c5b8cb6..69739a2 100644
--- a/spec/ruby/library/matrix/unitary_spec.rb
+++ b/spec/ruby/library/matrix/unitary_spec.rb
@@ -8,14 +8,11 @@ describe "Matrix.unitary?" do https://github.com/ruby/ruby/blob/trunk/spec/ruby/library/matrix/unitary_spec.rb#L8
     Matrix[[1, 1, 0], [0, 1, 1], [1, 0, 1]].unitary?.should == false
   end
 
-  ruby_version_is '2.8' do # matrix v0.3.0
-    it "returns true for non unitary matrix" do
-      Matrix[[0, Complex(0, 1)], [Complex(0, -1), 0]].unitary?.should == true
-    end
-  end
-
   it "returns true for unitary matrices" do
     Matrix[[0, Complex(0, 1)], [Complex(0, 1), 0]].unitary?.should == true
+    version_is((Matrix::const_defined?(:VERSION) ? Matrix::VERSION : "0.1.0"), "0.3.0") do
+      Matrix[[0, Complex(0, 1)], [Complex(0, -1), 0]].unitary?.should == true
+    end
   end
 
   it "raises an error for rectangular matrices" do
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]