LaravelDaily / laravel-invoices

Laravel package to generate PDF invoices from various customizable parameters

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

php unit test keep receiving error: Invoice: unable to set tax twice

MattWiseParking opened this issue · comments

Hi

Im not too sure why but my php unit tests keep erroring with exception: Invoice: unable to set tax twice
If i run the code manually without phpunit it works fine, not too sure why I would be receiving this error in unit tests.

I can see that the Exception is set in vendor/laraveldaily/laravel-invoices/src/Traits line 58 where it checks if $this->hasTax()

Would be great if you could help

Thanks :)

issue was because in the factory i was declairing fields to create the tax multiple ways when in stead you should only use one field.