public function JsonLogDataTest::testLinkAndCodeWillAlwaysBeSetAccordinglyWithZero in JSONlog 8
Same name and namespace in other branches
- 8.2 tests/src/Unit/JsonLogDataTest.php \Drupal\Tests\jsonlog\Unit\JsonLogDataTest::testLinkAndCodeWillAlwaysBeSetAccordinglyWithZero()
- 3.x tests/src/Unit/JsonLogDataTest.php \Drupal\Tests\jsonlog\Unit\JsonLogDataTest::testLinkAndCodeWillAlwaysBeSetAccordinglyWithZero()
File
- tests/
src/ Unit/ JsonLogDataTest.php, line 197
Class
- JsonLogDataTest
- Unit tests for JsonLogData class
Namespace
Drupal\Tests\jsonlog\UnitCode
public function testLinkAndCodeWillAlwaysBeSetAccordinglyWithZero() {
$this->data = new JsonLogData('test_site_id', 'test_canonical');
$this->data
->setLink(0);
$this
->assertNull($this->data
->getLink(), 'Link not set.');
$this
->assertEquals(0, $this->data
->getCode(), 'Code not set.');
}