updated-packages

This commit is contained in:
RafficMohammed
2023-01-08 00:13:22 +05:30
parent 3ff7df7487
commit da241bacb6
12659 changed files with 563377 additions and 510538 deletions

View File

@@ -9,8 +9,11 @@
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace Gitonomy\Git\Tests;
use Gitonomy\Git\Exception\RuntimeException;
class BlobTest extends AbstractTest
{
const README_FRAGMENT = 'Foo Bar project';
@@ -27,15 +30,20 @@ class BlobTest extends AbstractTest
{
$blob = $this->getReadmeBlob($repository);
$this->assertContains(self::README_FRAGMENT, $blob->getContent());
if (method_exists($this, 'assertStringContainsString')) {
$this->assertStringContainsString(self::README_FRAGMENT, $blob->getContent());
} else {
$this->assertContains(self::README_FRAGMENT, $blob->getContent());
}
}
/**
* @dataProvider provideFoobar
* @expectedException RuntimeException
*/
public function testNotExisting($repository)
{
$this->expectException(RuntimeException::class);
$blob = $repository->getBlob('foobar');
$blob->getContent();
}
@@ -46,7 +54,12 @@ class BlobTest extends AbstractTest
public function testGetMimetype($repository)
{
$blob = $this->getReadmeBlob($repository);
$this->assertRegexp('#text/plain#', $blob->getMimetype());
if (method_exists($this, 'assertMatchesRegularExpression')) {
$this->assertMatchesRegularExpression('#text/plain#', $blob->getMimetype());
} else {
$this->assertRegExp('#text/plain#', $blob->getMimetype());
}
}
/**