public function VersionNegotiatorTest::testInvalidRevisionId in JSON:API 8.2
@covers \Drupal\jsonapi\Revisions\VersionById::getRevision
File
- tests/
src/ Kernel/ Revisions/ VersionNegotiatorTest.php, line 136
Class
- VersionNegotiatorTest
- The test class for version negotiators.
Namespace
Drupal\Tests\jsonapi\Kernel\RevisionsCode
public function testInvalidRevisionId() {
$this
->setExpectedException(CacheableNotFoundHttpException::class, sprintf('The requested version, identified by `id:%s`, could not be found.', $this->node2
->getRevisionId()));
$this->versionNegotiator
->getRevision($this->node, 'id:' . $this->node2
->getRevisionId());
}