When accessing empty model many to many relationships you get a SQLSTATE[HY000]: General error: 1 no such table: the_pivot_table_name exception.
How to replicate
-
Clone https://github.com/johncarter-/laravel-orbit-many-to-many
-
Switch to the issue/many-to-many-no-such-table branch.
-
Run php artisan test --filter it_can_handle_empty_many_to_many_relationships tests/Feature/OrbitalManyToManyTest.php