diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 8f1068312..0a9a88278 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -148,3 +148,57 @@ jobs: - name: "Run PHPUnit" run: "php bin/phpunit -v" + + phpunit-without-rmq-redis: + name: "PHP ${{ matrix.php }} using ${{ matrix.database }} without Rabbit & Redis" + runs-on: "ubuntu-20.04" + + strategy: + fail-fast: false + matrix: + php: + - "8.3" + database: + - "sqlite" + - "mysql" + - "pgsql" + + steps: + - name: "Checkout" + uses: "actions/checkout@v4" + with: + fetch-depth: 2 + + - name: "Install PHP" + uses: "shivammathur/setup-php@v2" + with: + php-version: "${{ matrix.php }}" + coverage: none + tools: pecl + extensions: json, pdo, pdo_mysql, pdo_sqlite, pdo_pgsql, curl, imagick, pgsql, gd, tidy + ini-values: "date.timezone=Europe/Paris" + + - name: "Setup MySQL" + if: "${{ matrix.database == 'mysql' }}" + run: | + sudo systemctl start mysql.service + sudo mysql -u root -proot -h 127.0.0.1 -e "CREATE DATABASE wallabag_test" + + - name: "Setup PostgreSQL" + if: "${{ matrix.database == 'pgsql' }}" + run: | + sudo systemctl start postgresql + sudo -u postgres psql -d template1 -c "CREATE USER wallabag WITH PASSWORD 'wallabagrocks' CREATEDB" + createdb -h localhost -p 5432 -U wallabag wallabag_test + pg_isready -d wallabag_test -h localhost -p 5432 -U wallabag + + - name: "Install dependencies with Composer" + uses: "ramsey/composer-install@v3" + with: + composer-options: "--optimize-autoloader --prefer-dist" + + - name: "Prepare database configuration" + run: cp app/config/tests/parameters_test.${{ matrix.database }}.yml app/config/parameters_test.yml + + - name: "Run PHPUnit" + run: "php bin/phpunit -v" diff --git a/app/config/services_rabbit.yml b/app/config/services_rabbit.yml index 2c01be3bb..e39ad8972 100644 --- a/app/config/services_rabbit.yml +++ b/app/config/services_rabbit.yml @@ -6,6 +6,7 @@ services: public: true Wallabag\Consumer\RabbitMQConsumerTotalProxy: + lazy: true arguments: $pocketConsumer: '@old_sound_rabbit_mq.import_pocket_consumer' $readabilityConsumer: '@old_sound_rabbit_mq.import_readability_consumer'