Skip to content
Snippets Groups Projects
Commit c4f18722 authored by Liam Morland's avatar Liam Morland
Browse files

Issue #3272770: Replace deprecated assertEqual() with assertEquals()

parent 9d1d2201
No related branches found
No related tags found
No related merge requests found
......@@ -97,7 +97,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// Verify the new values have been submitted *and* successfully saved.
$this->assertSession()->pageTextContains('The configuration options have been saved.');
$this->assertSession()->fieldValueEquals('template_scheme', 'private');
$this->assertEqual($this->config('fillpdf.settings')->get('template_scheme'), 'private');
$this->assertEquals($this->config('fillpdf.settings')->get('template_scheme'), 'private');
// Now remove the private path from settings.php and rebuild the container.
$this->writeSettings([
......@@ -118,7 +118,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// Verify that the site default scheme, which at this point is 'public', is
// preselected but not yet saved in config.
$this->assertSession()->fieldValueEquals('template_scheme', $this->config('system.file')->get('default_scheme'));
$this->assertEqual($this->config('fillpdf.settings')->get('template_scheme'), 'private');
$this->assertEquals($this->config('fillpdf.settings')->get('template_scheme'), 'private');
}
/**
......@@ -134,7 +134,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// and in config.
$this->drupalGet(Url::fromRoute('fillpdf.settings'));
$this->assertSession()->fieldValueEquals('template_scheme', 'public');
$this->assertEqual($this->config('fillpdf.settings')->get('template_scheme'), 'public');
$this->assertEquals($this->config('fillpdf.settings')->get('template_scheme'), 'public');
// Verify the subdirectory doesn't exist yet.
$directory = 'public://fillpdf';
......@@ -171,7 +171,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// both submitted and stored.
$this->assertSession()->pageTextContains('The configuration options have been saved.');
$this->assertSession()->fieldValueEquals('backend', 'fillpdf_service');
$this->assertEqual($this->config('fillpdf.settings')->get('backend'), 'fillpdf_service');
$this->assertEquals($this->config('fillpdf.settings')->get('backend'), 'fillpdf_service');
// Now add an API key and save again.
$this->drupalPostForm(NULL, ['fillpdf_service_api_key' => 'Invalid, just playing around.'], 'Save configuration');
......@@ -180,7 +180,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// 'fillpdf_service_api_key' should be both submitted and stored.
$this->assertSession()->pageTextContains('The configuration options have been saved.');
$this->assertSession()->fieldValueEquals('fillpdf_service_api_key', 'Invalid, just playing around.');
$this->assertEqual($this->config('fillpdf.settings')->get('fillpdf_service_api_key'), 'Invalid, just playing around.');
$this->assertEquals($this->config('fillpdf.settings')->get('fillpdf_service_api_key'), 'Invalid, just playing around.');
}
/**
......@@ -203,7 +203,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
// Verify the new values have been submitted, but *not* saved.
foreach ($edit as $field => $value) {
$this->assertSession()->fieldValueEquals($field, $value);
$this->assertEqual($this->config('fillpdf.settings')->get($field), NULL);
$this->assertEquals($this->config('fillpdf.settings')->get($field), NULL);
}
}
......@@ -238,7 +238,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
foreach ($edit as $field => $value) {
$this->assertSession()->fieldValueEquals($field, $value);
$config_name = $field === 'example_setting' ? 'fillpdf_test.settings' : 'fillpdf.settings';
$this->assertEqual($this->config($config_name)->get($field), NULL);
$this->assertEquals($this->config($config_name)->get($field), NULL);
}
// Try again with a valid value.
......@@ -254,7 +254,7 @@ class FillPdfSettingsFormTest extends BrowserTestBase {
foreach ($expected as $field => $value) {
$this->assertSession()->fieldValueEquals($field, $value);
$config_name = $field === 'example_setting' ? 'fillpdf_test.settings' : 'fillpdf.settings';
$this->assertEqual($this->config($config_name)->get($field), $value);
$this->assertEquals($this->config($config_name)->get($field), $value);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment