assertEquals( "29783464603523", $gtin14, "It should convert to GTIN-14" ); } public function testFormatGtin14WithDefaultPrefix() { $gtin14 = Isbn::convertToGtin14("9783464603529"); $this->assertEquals( "19783464603526", $gtin14, "It should convert to GTIN-14 using 1 as default prefix" ); } public function testFormatGtin14InvalidIsbn() { $this->expectException("Biblys\Isbn\IsbnParsingException"); $this->expectExceptionMessage("Invalid characters in the code"); Isbn::convertToGtin14("ABC-80-7203-7", 1); } }