use Drupal\comment\Entity\Comment;
use Drupal\comment\Tests\CommentTestTrait;
-use Drupal\Component\Utility\Unicode;
use Drupal\Core\Url;
use Drupal\field\Entity\FieldConfig;
use Drupal\field\Entity\FieldStorageConfig;
// Try to upload exactly the allowed number of files on revision. Create an
// empty node first, to fill it in its first revision.
$node = $this->drupalCreateNode([
- 'type' => $type_name
+ 'type' => $type_name,
]);
$this->uploadNodeFile($test_file, $field_name, $node->id(), 1);
$node_storage->resetCache([$nid]);
* Tests file widget element.
*/
public function testWidgetElement() {
- $field_name = Unicode::strtolower($this->randomMachineName());
+ $field_name = mb_strtolower($this->randomMachineName());
$html_name = str_replace('_', '-', $field_name);
$this->createFileField($field_name, 'node', 'article', ['cardinality' => FieldStorageConfig::CARDINALITY_UNLIMITED]);
$file = $this->getTestFile('text');