public function ChainTaxCodeResolverTest::testNonProductVariationTaxCodeResolver in Drupal Commerce Connector for AvaTax 8
Tests resolving a generic purchasable entity.
There should be nothing resolved, which allows Avalara to use the system default.
File
- tests/
src/ Kernel/ ChainTaxCodeResolverTest.php, line 90
Class
- ChainTaxCodeResolverTest
- Tests the chain tax code resolver.
Namespace
Drupal\Tests\commerce_avatax\KernelCode
public function testNonProductVariationTaxCodeResolver() {
$purchased_entity = $this
->prophesize(PurchasableEntityInterface::class);
$order_item = $this
->prophesize(OrderItemInterface::class);
$order_item
->getPurchasedEntity()
->willReturn($purchased_entity
->reveal());
$resolved_code = $this->container
->get('commerce_avatax.chain_tax_code_resolver')
->resolve($order_item
->reveal());
$this
->assertEquals(NULL, $resolved_code);
}