General error: 1 no such table: sqlite_sequence

[Editied for clarity]

Lured by the elegance of cakephp-fixture-factories which was demo’d at the recent meetup, I did the install today.

…and ran afoul of

Exception: SQLSTATE[HY000]: 
General error:
1 no such table: sqlite_sequence
In [...cakephp/cakephp/src/Database/Driver/Sqlite.php, line 120]
Full output of test attempt
Testing started at 6:24 PM ...
/usr/local/Cellar/php/7.3.9_1/bin/php 
/Library/WebServer/Documents/ampfg4/vendor/phpunit/phpunit/phpunit 
--configuration /Library/WebServer/Documents/ampfg4/phpunit.xml.dist 
/Library/WebServer/Documents/ampfg4/tests --teamcity
PHPUnit 8.5.4 by Sebastian Bergmann and contributors.

Exception: SQLSTATE[HY000]: General error: 1 no such table: sqlite_sequence
In [/Library/WebServer/Documents/ampfg4/vendor/cakephp/cakephp/src/Database/Driver/Sqlite.php, line 120]

Process finished with exit code 1

The installation instructions state explicitly “the fixtures will be created in the test database(s) defined in your configuration.”

My test configuration performs as expected prior to plugin install.

I’ve traced the error to the addition of a Listener in phpunit.xml. This listener is a required part of the installation of the fixture plugin. I left the original Cake listeners in place too (as allowed by the installation instructions).

<listener class="CakephpFixtureFactories\TestSuite\FixtureInjector">
    <arguments>
        <object class="CakephpFixtureFactories\TestSuite\FixtureManager" />
    </arguments>
</listener>
Full phpunit xml
<?xml version="1.0" encoding="UTF-8"?>
<phpunit
    colors="true"
    processIsolation="false"
    stopOnFailure="false"
    bootstrap="tests/bootstrap.php"
    >
    <php>
        <ini name="memory_limit" value="-1"/>
        <ini name="apc.enable_cli" value="1"/>
    </php>

    <!-- Add any additional test suites you want to run here -->
    <testsuites>
        <testsuite name="app">
            <directory>tests/TestCase/</directory>
        </testsuite>
        <!-- Add plugin test suites here. -->
    </testsuites>

    <!-- Setup a listener for fixtures -->
    <listeners>
        <listener class="CakephpFixtureFactories\TestSuite\FixtureInjector">
            <arguments>
                <object class="CakephpFixtureFactories\TestSuite\FixtureManager" />
            </arguments>
        </listener>
        <listener class="Cake\TestSuite\Fixture\FixtureInjector">
            <arguments>
                <object class="Cake\TestSuite\Fixture\FixtureManager"/>
            </arguments>
        </listener>
    </listeners>

    <!-- Ignore vendor tests in code coverage reports -->
    <filter>
        <whitelist>
            <directory suffix=".php">src/</directory>
            <directory suffix=".php">plugins/*/src/</directory>
            <exclude>
                <file>src/Console/Installer.php</file>
            </exclude>
        </whitelist>
    </filter>
</phpunit>

So it seems like there is something else I should be doing in the setup… But I’m out past the boundaries of my knowledge and into follow-directions-and-guess territory.

I did see some stuff around the web about tmp directory permissions and sqlite but fiddling with that has not got me working yet…