When I was testing the File.zero? I noticed File.zero?(''NUL'')
failed. I looked the code and it seems there is no special check there to
exclude NUL as a not a valid file. I created a constant
??????? private readonly static string NUL_VALUE = "NUL";
and added a else clause in the trycreate method? as
else if (path.Equals(NUL_VALUE))
??????????????? {
??????????????????? result = null;
??????????????? }
and now the NUL works fine for zero.
I have two questions with this regard;
1. Can I apply these changes and push in the patch?
2. When we run the rake spec, will it include following tests on Windows?
platform :not, :mswin do
??? it "returns true for /dev/null" do
????? File.zero?(''/dev/null'').should == true
??? end
? end
It seems it does,
I haven''t looked at the Rubinius to see how the platform is supposed to
work.
Thanks,
unni
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20080705/ff491bc7/attachment.html>
You should be fine making a patch. As for the test, it shouldn''t run
that test on Windows, but I''m not sure how the old runner works.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 1:22 AM
Subject: [Ironruby-core] spec question
When I was testing the File.zero? I noticed File.zero?(''NUL'')
failed. I looked the code and it seems there is no special check there to
exclude NUL as a not a valid file. I created a constant
private readonly static string NUL_VALUE = "NUL";
and added a else clause in the trycreate method as
else if (path.Equals(NUL_VALUE))
{
result = null;
}
and now the NUL works fine for zero.
I have two questions with this regard;
1. Can I apply these changes and push in the patch?
2. When we run the rake spec, will it include following tests on Windows?
platform :not, :mswin do
it "returns true for /dev/null" do
File.zero?(''/dev/null'').should == true
end
end
It seems it does, I haven''t looked at the Rubinius to see how the
platform is supposed to work.
Thanks,
unni
<http://rubini.us/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20080705/69a028cd/attachment-0001.html>
Jim,
?
Now that we moved to GIT, do we submit the patches through GIT?
?
Thanks
Unni
--- On Sat, 7/5/08, Jim Deville <jdeville at microsoft.com> wrote:
From: Jim Deville <jdeville at microsoft.com>
Subject: RE: [Ironruby-core] spec question
To: "ksunair at yahoo.com" <ksunair at yahoo.com>,
"ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Date: Saturday, July 5, 2008, 2:16 PM
You should be fine making a patch. As for the test, it shouldn''t run
that test on Windows, but I''m not sure how the old runner works.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 1:22 AM
Subject: [Ironruby-core] spec question
When I was testing the File.zero? I noticed File.zero?(''NUL'')
failed. I looked the code and it seems there is no special check there to
exclude NUL as a not a valid file. I created a constant
??????? private readonly static string NUL_VALUE = "NUL";
and added a else clause in the trycreate method? as
else if (path.Equals(NUL_VALUE))
??????????????? {
??????????????????? result = null;
??????????????? }
and now the NUL works fine for zero.
I have two questions with this regard;
1. Can I apply these changes and push in the patch?
2. When we run the rake spec, will it include following tests on Windows?
platform :not, :mswin do
??? it "returns true for /dev/null" do
????? File.zero?(''/dev/null'').should == true
??? end
? end
It seems it does, I haven''t looked at the Rubinius to see how the
platform is supposed to work.
Thanks,
unni
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20080705/d44a056a/attachment.html>
I''d say yes. You can commit to your local repository and use "git
format-patch -1" to make the patches. Change the number to match the number
of commits you have made.
In addition, remember that rake spec runs the tests in tests/core, which
isn''t the same as the git tests.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 11:07 PM
Subject: Re: [Ironruby-core] spec question
Jim,
Now that we moved to GIT, do we submit the patches through GIT?
Thanks
Unni
--- On Sat, 7/5/08, Jim Deville <jdeville at microsoft.com> wrote:
From: Jim Deville <jdeville at microsoft.com>
Subject: RE: [Ironruby-core] spec question
To: "ksunair at yahoo.com" <ksunair at yahoo.com>,
"ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Date: Saturday, July 5, 2008, 2:16 PM
You should be fine making a patch. As for the test, it shouldn''t run
that test on Windows, but I''m not sure how the old runner works.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 1:22 AM
Subject: [Ironruby-core] spec question
When I was testing the File.zero? I noticed File.zero?(''NUL'')
failed. I looked the code and it seems there is no special check there to
exclude NUL as a not a valid file. I created a constant
private readonly static string NUL_VALUE = "NUL";
and added a else clause in the trycreate method as
else if (path.Equals(NUL_VALUE))
{
result = null;
}
and now the NUL works fine for zero.
I have two questions with this regard;
1. Can I apply these changes and push in the patch?
2. When we run the rake spec, will it include following tests on Windows?
platform :not, :mswin do
it "returns true for /dev/null" do
File.zero?(''/dev/null'').should == true
end
end
It seems it does, I haven''t looked at the Rubinius to see how the
platform is supposed to work.
Thanks,
unni
<http://rubini.us/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20080706/78608a2e/attachment.html>
Jim,
?
?
I put the patch on the rubyforge while I am getting used to GIT. Sorry.
[#21102] Updated File/Zero method to handle NUL
I am running all the spec against my sample codes I have and instead of sending
one by one I will try to send couple of them together.
?
Thanks.
--- On Sun, 7/6/08, Jim Deville <jdeville at microsoft.com> wrote:
From: Jim Deville <jdeville at microsoft.com>
Subject: RE: [Ironruby-core] spec question
To: "ksunair at yahoo.com" <ksunair at yahoo.com>,
"ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Date: Sunday, July 6, 2008, 4:57 AM
I''d say yes. You can commit to your local repository and use "git
format-patch -1" to make the patches. Change the number to match the number
of commits you have made.
In addition, remember that rake spec runs the tests in tests/core, which
isn''t the same as the git tests.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 11:07 PM
Subject: Re: [Ironruby-core] spec question
Jim,
?
Now that we moved to GIT, do we submit the patches through GIT?
?
Thanks
Unni
--- On Sat, 7/5/08, Jim Deville <jdeville at microsoft.com> wrote:
From: Jim Deville <jdeville at microsoft.com>
Subject: RE: [Ironruby-core] spec question
To: "ksunair at yahoo.com" <ksunair at yahoo.com>,
"ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Date: Saturday, July 5, 2008, 2:16 PM
You should be fine making a patch. As for the test, it shouldn''t run
that test on Windows, but I''m not sure how the old runner works.
JD
-----Original Message-----
From: "Unnikrishnan Nair" <ksunair at yahoo.com>
To: "ironruby-core at rubyforge.org" <ironruby-core at
rubyforge.org>
Sent: 7/5/08 1:22 AM
Subject: [Ironruby-core] spec question
When I was testing the File.zero? I noticed File.zero?(''NUL'')
failed. I looked the code and it seems there is no special check there to
exclude NUL as a not a valid file. I created a constant
??????? private readonly static string NUL_VALUE = "NUL";
and added a else clause in the trycreate method? as
else if (path.Equals(NUL_VALUE))
??????????????? {
??????????????????? result = null;
??????????????? }
and now the NUL works fine for zero.
I have two questions with this regard;
1. Can I apply these changes and push in the patch?
2. When we run the rake spec, will it include following tests on Windows?
platform :not, :mswin do
??? it "returns true for /dev/null" do
????? File.zero?(''/dev/null'').should == true
??? end
? end
It seems it does, I haven''t looked at the Rubinius to see how the
platform is supposed to work.
Thanks,
unni
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20080706/35350259/attachment-0001.html>