public function SimpletestDeprecationTest::testDeprecatedSimpletestGenerateFile in SimpleTest 8.3
@expectedDeprecation simpletest_generate_file() is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use \Drupal\Tests\TestFileCreationTrait::generateFile() instead. See https://www.drupal.org/node/3077768
File
- tests/
src/ Kernel/ SimpletestDeprecationTest.php, line 88
Class
- SimpletestDeprecationTest
- Verify deprecations within the simpletest module.
Namespace
Drupal\Tests\simpletest\KernelCode
public function testDeprecatedSimpletestGenerateFile() {
$file = simpletest_generate_file('foo', 40, 10);
$public_file = 'public://' . $file . '.txt';
$this
->assertFileExists($public_file);
$this
->assertTrue(unlink($public_file));
}