Mock EntityTypeManager
> OK, but incomplete, skipped, or risky tests! > Tests: 1, Assertions: 0, Risky: 1.
This commit is contained in:
parent
bad5ba5905
commit
6e00df9ccc
|
@ -2,6 +2,7 @@
|
|||
|
||||
namespace Drupal\Tests\example\Unit;
|
||||
|
||||
use Drupal\Core\Entity\EntityTypeManagerInterface;
|
||||
use Drupal\example\Repository\PostNodeRepository;
|
||||
use Drupal\Tests\UnitTestCase;
|
||||
|
||||
|
@ -13,7 +14,7 @@ final class PostNodeRepositoryUnitTest extends UnitTestCase {
|
|||
/** @test */
|
||||
public function it_returns_posts(): void {
|
||||
$repository = new PostNodeRepository(
|
||||
new EntityTypeManager(),
|
||||
$this->createMock(EntityTypeManagerInterface::class),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue