diff --git a/core/includes/bootstrap.inc b/core/includes/bootstrap.inc index 03572a6..bedf474 100644 --- a/core/includes/bootstrap.inc +++ b/core/includes/bootstrap.inc @@ -344,7 +344,7 @@ function t($string, array $args = array(), array $options = array()) { * @see t() * @ingroup sanitization */ -function format_string($string, array $args = array()) { +function format_string($string, array $args) { return SafeMarkup::format($string, $args); } diff --git a/core/modules/config/src/Tests/ConfigFileContentTest.php b/core/modules/config/src/Tests/ConfigFileContentTest.php index 1347db5..8818f41 100644 --- a/core/modules/config/src/Tests/ConfigFileContentTest.php +++ b/core/modules/config/src/Tests/ConfigFileContentTest.php @@ -121,16 +121,16 @@ function testReadWriteConfig() { $this->assertNull($config->get('i.dont.exist'), 'Non-existent nested value returned NULL.'); // Read false value. - $this->assertEqual($config->get($false_key), '0', format_string("Boolean FALSE value returned the string '0'.")); + $this->assertEqual($config->get($false_key), '0', "Boolean FALSE value returned the string '0'."); // Read true value. - $this->assertEqual($config->get($true_key), '1', format_string("Boolean TRUE value returned the string '1'.")); + $this->assertEqual($config->get($true_key), '1', "Boolean TRUE value returned the string '1'."); // Read null value. $this->assertIdentical($config->get('null'), NULL); // Read false that had been nested in an array value. - $this->assertEqual($config->get($casting_array_false_value_key), '0', format_string("Nested boolean FALSE value returned the string '0'.")); + $this->assertEqual($config->get($casting_array_false_value_key), '0', "Nested boolean FALSE value returned the string '0'."); // Unset a top level value. $config->clear($key); diff --git a/core/modules/field/src/Tests/String/RawStringFormatterTest.php b/core/modules/field/src/Tests/String/RawStringFormatterTest.php index 020a2e3..82f6973 100644 --- a/core/modules/field/src/Tests/String/RawStringFormatterTest.php +++ b/core/modules/field/src/Tests/String/RawStringFormatterTest.php @@ -123,7 +123,7 @@ public function testStringFormatter() { // Verify the cache tags. $build = $entity->{$this->fieldName}->view(); - $this->assertTrue(!isset($build[0]['#cache']), format_string('The string formatter has no cache tags.')); + $this->assertTrue(!isset($build[0]['#cache']), 'The string formatter has no cache tags.'); } } diff --git a/core/modules/field/src/Tests/String/StringFormatterTest.php b/core/modules/field/src/Tests/String/StringFormatterTest.php index 4af818e..dcb515e 100644 --- a/core/modules/field/src/Tests/String/StringFormatterTest.php +++ b/core/modules/field/src/Tests/String/StringFormatterTest.php @@ -123,7 +123,7 @@ public function testStringFormatter() { // Verify the cache tags. $build = $entity->{$this->fieldName}->view(); - $this->assertTrue(!isset($build[0]['#cache']), format_string('The string formatter has no cache tags.')); + $this->assertTrue(!isset($build[0]['#cache']), 'The string formatter has no cache tags.'); $value = $this->randomMachineName(); $entity->{$this->fieldName}->value = $value; diff --git a/core/modules/system/src/Tests/Ajax/FrameworkTest.php b/core/modules/system/src/Tests/Ajax/FrameworkTest.php index c7ccd8b..6ab1c5e 100644 --- a/core/modules/system/src/Tests/Ajax/FrameworkTest.php +++ b/core/modules/system/src/Tests/Ajax/FrameworkTest.php @@ -165,7 +165,7 @@ public function testLazyLoad() { // the first AJAX command. $this->assertIdentical($new_settings[$expected['setting_name']], $expected['setting_value'], format_string('Page now has the %setting.', array('%setting' => $expected['setting_name']))); $expected_command = new SettingsCommand(array($expected['setting_name'] => $expected['setting_value']), TRUE); - $this->assertCommand(array_slice($commands, 0, 1), $expected_command->render(), format_string('The settings command was first.')); + $this->assertCommand(array_slice($commands, 0, 1), $expected_command->render(), 'The settings command was first.'); // Verify the expected CSS file was added, both to drupalSettings, and as // the second AJAX command for inclusion into the HTML. diff --git a/core/modules/system/src/Tests/Entity/EntityQueryTest.php b/core/modules/system/src/Tests/Entity/EntityQueryTest.php index fd4165b..4130804 100644 --- a/core/modules/system/src/Tests/Entity/EntityQueryTest.php +++ b/core/modules/system/src/Tests/Entity/EntityQueryTest.php @@ -554,7 +554,7 @@ protected function assertBundleOrder($order) { } } } - $this->assertTrue($ok, format_string("$i is after all entities in bundle2")); + $this->assertTrue($ok, "$i is after all entities in bundle2"); } } diff --git a/core/modules/system/src/Tests/Path/AliasTest.php b/core/modules/system/src/Tests/Path/AliasTest.php index 4281905..2ceb4c9 100644 --- a/core/modules/system/src/Tests/Path/AliasTest.php +++ b/core/modules/system/src/Tests/Path/AliasTest.php @@ -52,7 +52,7 @@ function testCRUD() { // Load alias by source path. $loadedAlias = $aliasStorage->load(array('source' => '/node/1')); - $this->assertEqual($loadedAlias['alias'], '/alias_for_node_1_und', format_string('The last created alias loaded by default.')); + $this->assertEqual($loadedAlias['alias'], '/alias_for_node_1_und', 'The last created alias loaded by default.'); //Update a few aliases foreach ($aliases as $alias) {