Thread overview
[phobos] unittest failures for std.file and std.datetime
May 07, 2011
Walter Bright
May 07, 2011
Jonathan M Davis
May 07, 2011
Jonathan M Davis
May 07, 2011
Walter Bright
May 07, 2011
Jonathan M Davis
May 06, 2011
Dunno which is at fault, but I erratically get the following on Windows:

core.exception.AssertError at std.file(779): unittest failure
----------------
615138
614FAF
5952ED
6098E6

May 06, 2011
> Dunno which is at fault, but I erratically get the following on Windows:
> 
> core.exception.AssertError at std.file(779): unittest failure
> ----------------
> 615138
> 614FAF
> 5952ED
> 6098E6

It's trying to verify that the times from the file are correct - such as the time that the file was created. Unfortunately, it can't verify it exactly and so it has a bit of leeway in its check - 2 seconds. Apparently, on your machine, that leeway is too small. I believe that you increased the leeway on the Posix version of the test to 4 seconds just the other day because the leeway wasn't enough on your machine. It's the exact same problem here, only it's on Windows. Ideally, the tests would be exact, but they can't be, and 2 seconds was generally working. Apparently, it's still not enough however.

- Jonathan M Davis
May 06, 2011
> > Dunno which is at fault, but I erratically get the following on Windows:
> > 
> > core.exception.AssertError at std.file(779): unittest failure
> > ----------------
> > 615138
> > 614FAF
> > 5952ED
> > 6098E6
> 
> It's trying to verify that the times from the file are correct - such as the time that the file was created. Unfortunately, it can't verify it exactly and so it has a bit of leeway in its check - 2 seconds. Apparently, on your machine, that leeway is too small. I believe that you increased the leeway on the Posix version of the test to 4 seconds just the other day because the leeway wasn't enough on your machine. It's the exact same problem here, only it's on Windows. Ideally, the tests would be exact, but they can't be, and 2 seconds was generally working. Apparently, it's still not enough however.

Ah, wait. You increased it on Windows. It was already 4 seconds on Linux for whatever reason. Is it still failing on your machine after you increased the leeway to 4 seconds?

- Jonathan M Davis
May 06, 2011

On 5/6/2011 7:13 PM, Jonathan M Davis wrote:
>>> Dunno which is at fault, but I erratically get the following on Windows:
>>>
>>> core.exception.AssertError at std.file(779): unittest failure
>>> ----------------
>>> 615138
>>> 614FAF
>>> 5952ED
>>> 6098E6
>> It's trying to verify that the times from the file are correct - such as the time that the file was created. Unfortunately, it can't verify it exactly and so it has a bit of leeway in its check - 2 seconds. Apparently, on your machine, that leeway is too small. I believe that you increased the leeway on the Posix version of the test to 4 seconds just the other day because the leeway wasn't enough on your machine. It's the exact same problem here, only it's on Windows. Ideally, the tests would be exact, but they can't be, and 2 seconds was generally working. Apparently, it's still not enough however.
> Ah, wait. You increased it on Windows. It was already 4 seconds on Linux for whatever reason. Is it still failing on your machine after you increased the leeway to 4 seconds?
>

Yes. And the unittests run start to finish in under 2 seconds, so I suspect it's not the leeway that's the problem.
May 06, 2011
> On 5/6/2011 7:13 PM, Jonathan M Davis wrote:
> >>> Dunno which is at fault, but I erratically get the following on Windows:
> >>> 
> >>> core.exception.AssertError at std.file(779): unittest failure
> >>> ----------------
> >>> 615138
> >>> 614FAF
> >>> 5952ED
> >>> 6098E6
> >> 
> >> It's trying to verify that the times from the file are correct - such as the time that the file was created. Unfortunately, it can't verify it exactly and so it has a bit of leeway in its check - 2 seconds. Apparently, on your machine, that leeway is too small. I believe that you increased the leeway on the Posix version of the test to 4 seconds just the other day because the leeway wasn't enough on your machine. It's the exact same problem here, only it's on Windows. Ideally, the tests would be exact, but they can't be, and 2 seconds was generally working. Apparently, it's still not enough however.
> > 
> > Ah, wait. You increased it on Windows. It was already 4 seconds on Linux for whatever reason. Is it still failing on your machine after you increased the leeway to 4 seconds?
> 
> Yes. And the unittests run start to finish in under 2 seconds, so I suspect it's not the leeway that's the problem.

Yeah. I wouldn't think so, but I have no clue why it would be failing otherwise. Obviously, I'll have to look into it.

- Jonathan M Davis