$file = new UploadedFile(__DIR__.'/../fixtures/wallabag-v2.json', 'wallabag-v2.json');
- $data = array(
+ $data = [
'upload_import_file[file]' => $file,
- );
+ ];
$client->submit($form, $data);
$crawler = $client->followRedirect();
- $this->assertGreaterThan(1, $body = $crawler->filter('body')->extract(array('_text')));
+ $this->assertGreaterThan(1, $body = $crawler->filter('body')->extract(['_text']));
$this->assertContains('flashes.import.notice.summary', $body[0]);
$content = $client->getContainer()
$file = new UploadedFile(__DIR__.'/../fixtures/test.txt', 'test.txt');
- $data = array(
+ $data = [
'upload_import_file[file]' => $file,
- );
+ ];
$client->submit($form, $data);
$crawler = $client->followRedirect();
- $this->assertGreaterThan(1, $body = $crawler->filter('body')->extract(array('_text')));
+ $this->assertGreaterThan(1, $body = $crawler->filter('body')->extract(['_text']));
$this->assertContains('flashes.import.notice.failed', $body[0]);
}
}