Skip to content

Commit 72a98b8

Browse files
Merge branch '2.3' into 2.7
* 2.3: Windows and Intl fixes Add appveyor.yml for C.I. on Windows [travis] merge php: nightly and deps=high test-matrix lines [Security] Add missing docblock in PreAuthenticatedToken Conflicts: .travis.yml src/Symfony/Component/Filesystem/Tests/FilesystemTest.php src/Symfony/Component/HttpFoundation/JsonResponse.php src/Symfony/Component/Intl/DateFormatter/IntlDateFormatter.php
2 parents 4c0885a + a7bd522 commit 72a98b8

File tree

3 files changed

+11
-7
lines changed

3 files changed

+11
-7
lines changed

Tests/Iterator/RecursiveDirectoryIteratorTest.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,6 @@ public function testSeek($path, $seekable, $contains, $message = null)
6060
$i->seek(1);
6161
$actual[] = $i->getPathname();
6262

63-
$i->seek(2);
64-
$actual[] = $i->getPathname();
65-
6663
$this->assertEquals($contains, $actual);
6764
}
6865

@@ -73,7 +70,6 @@ public function getPaths()
7370
// ftp
7471
$contains = array(
7572
'ftp://ftp.mozilla.org'.DIRECTORY_SEPARATOR.'README',
76-
'ftp://ftp.mozilla.org'.DIRECTORY_SEPARATOR.'index.html',
7773
'ftp://ftp.mozilla.org'.DIRECTORY_SEPARATOR.'pub',
7874
);
7975
$data[] = array('ftp://ftp.mozilla.org/', false, $contains);

Tests/Iterator/SortableIteratorTest.php

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ public function testAccept($mode, $expected)
3333
if (!is_callable($mode)) {
3434
switch ($mode) {
3535
case SortableIterator::SORT_BY_ACCESSED_TIME :
36-
file_get_contents(self::toAbsolute('.git'));
36+
if ('\\' === DIRECTORY_SEPARATOR) {
37+
touch(self::toAbsolute('.git'));
38+
} else {
39+
file_get_contents(self::toAbsolute('.git'));
40+
}
3741
sleep(1);
3842
file_get_contents(self::toAbsolute('.bar'));
3943
break;
@@ -56,7 +60,11 @@ public function testAccept($mode, $expected)
5660

5761
if ($mode === SortableIterator::SORT_BY_ACCESSED_TIME
5862
|| $mode === SortableIterator::SORT_BY_CHANGED_TIME
59-
|| $mode === SortableIterator::SORT_BY_MODIFIED_TIME) {
63+
|| $mode === SortableIterator::SORT_BY_MODIFIED_TIME
64+
) {
65+
if ('\\' === DIRECTORY_SEPARATOR && SortableIterator::SORT_BY_MODIFIED_TIME !== $mode) {
66+
$this->markTestSkipped('Sorting by atime or ctime is not supported on Windows');
67+
}
6068
$this->assertOrderedIteratorForGroups($expected, $iterator);
6169
} else {
6270
$this->assertOrderedIterator($expected, $iterator);

Tests/Shell/CommandTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public function testArg()
8686
$cmd = Command::create()->add('--force');
8787

8888
$cmd->arg('--run');
89-
$this->assertSame('--force \'--run\'', $cmd->join());
89+
$this->assertSame('--force '.escapeshellarg('--run'), $cmd->join());
9090
}
9191

9292
public function testCmd()

0 commit comments

Comments
 (0)