[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#36940: tests slowness and failure after recent Tramp changes

From: Michael Albinus
Subject: bug#36940: tests slowness and failure after recent Tramp changes
Date: Sat, 10 Aug 2019 11:43:33 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Paul Eggert <address@hidden> writes:

Hi Paul,

> Your patch has several instances of (floor (float-time X)) that would
> be slightly better if written as (time-convert X 'integer), as the
> former has (unlikely) rounding errors that the latter lacks.
> I assume that the test now uses integer timestamps because file
> systems routinely drop low-order parts of timestamps. But won't the
> test continue to have problems with filesystems whose timestamp
> resolution is 2 seconds? I have heard of such things.

Thanks for the explanation.

Honestly, we have also a further problem. The tests compare time values
taken on different machines. It cannot be assumed that they are always
synchronized. Until now it works, but who knows.

The tests in tramp--test-file-attributes-equal-p do not require exact
time stamps. They just want to ensure, that time values in file
attributes are newer than the time the ert test case has started. I've
changed the test such a way, that it is compared with the start time
minus 60 seconds. This solves the two problems you have mentioned, and
it also allows a time offset of up to 60 seconds for the two machines in
question. This shall suffice for most of the caes in practice.

A more precise test would be to retrieve the ert test start time, as taken
from the remote machine. But I don't know of a general function doing this.

Best regards, Michael.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]