Skip to content

Commit

Permalink
Message in new tests, php version to 7.1
Browse files Browse the repository at this point in the history
  • Loading branch information
alphp committed Apr 10, 2022
1 parent b747539 commit 4c1b56e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion composer.json
Expand Up @@ -13,7 +13,7 @@
"source": "https://github.com/alphp/strftime"
},
"require": {
"php": ">=5.6.0",
"php": ">=7.1.0",
"ext-intl" : "*"
},
"require-dev": {
Expand Down
6 changes: 3 additions & 3 deletions tests/strftimeTest.php
Expand Up @@ -190,16 +190,16 @@ public function testJulianCutover () {
// 1st October 1582 in proleptic Gregorian is the same date as 21st September 1582 Julian
$prolepticTimestamp = DateTimeImmutable::createFromFormat('Y-m-d|', '1582-10-01')->getTimestamp();
$result = strftime('%x', $prolepticTimestamp, 'eu');
$this->assertEquals('82/10/1', $result);
$this->assertEquals('82/10/1', $result, '1st October 1582 in proleptic Gregorian is the same date as 21st September 1582 Julian');

// In much of Europe, the 10th October 1582 never existed
$prolepticTimestamp = DateTimeImmutable::createFromFormat('Y-m-d|', '1582-10-10')->getTimestamp();
$result = strftime('%x', $prolepticTimestamp, 'eu');
$this->assertEquals('82/10/10', $result);
$this->assertEquals('82/10/10', $result, 'In much of Europe, the 10th October 1582 never existed');

// The 15th October was the first day after the cutover, after which both systems agree
$prolepticTimestamp = DateTimeImmutable::createFromFormat('Y-m-d|', '1582-10-15')->getTimestamp();
$result = strftime('%x', $prolepticTimestamp, 'eu');
$this->assertEquals('82/10/15', $result);
$this->assertEquals('82/10/15', $result, 'The 15th October was the first day after the cutover, after which both systems agree');
}
}

0 comments on commit 4c1b56e

Please sign in to comment.