We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent af52c91 commit c5c8229Copy full SHA for c5c8229
1 file changed
tests/unit/Term/TermListTest.php
@@ -467,4 +467,16 @@ public function testCanConstructWithIterables() {
467
$this->assertEquals( $deTerm, $terms->getByLanguage( 'de' ) );
468
}
469
470
+ public function testWhenProvidingNonTerms_constructorThrowsException() {
471
+ $this->setExpectedException( InvalidArgumentException::class );
472
+ new TermList( [ 'no-a-term' ] );
473
+ }
474
+
475
+ public function testWhenProvidingNonTerms_addAllThrowsException() {
476
+ $list = new TermList( [] );
477
478
479
+ $list->addAll( [ 'no-a-term' ] );
480
481
482
0 commit comments