rollback.t: Get rid of stat

Using stat to get the last edit timestamp can lead to a failing test.
To be absolutely certain, use the timestamp stored in the page file.
As it stands, $Now is used for the timestamp in the page file but if
this is a new file (revision 1), then the index file gets rewritten
and its timestamp changes.
This commit is contained in:
Alex Schroeder
2014-06-22 23:11:35 +02:00
parent a226902617
commit e9375974cb

View File

@@ -154,7 +154,8 @@ test_page_negative($page,
# test url encoding
test_page(update_page('Schröder', 'Alex', 'eins'), 'Alex');
$to = (stat($IndexFile))[9];
OpenPage('Schröder');
$to = $Page{ts};
sleep(1);
test_page(update_page('HiddenEdit', 'not to be rolled back', 'secret'), 'not to be rolled back');
test_page(update_page('Schröder', 'Berta', 'zwei'), 'Berta');