diff --git a/.forgejo/workflows/phpunit.yml b/.forgejo/workflows/phpunit.yml index 2b54af1..7bc8ec0 100644 --- a/.forgejo/workflows/phpunit.yml +++ b/.forgejo/workflows/phpunit.yml @@ -43,11 +43,12 @@ jobs: - name: Install mysqladmin run: sudo apt update && sudo apt -y upgrade && sudo apt -y install mysql-client + - name: Clone plugin dependencies + run: git clone https://code.event-federation.eu/Event-Federation/wordpress-activitypub.git /tmp/wordpress/wp-content/plugins/activitypub/ + - name: Setup Test Environment run: bash bin/install-wp-tests.sh wordpress_test root root 127.0.0.1 latest - - run: cat /tmp/wordpress-tests-lib/wp-tests-config.php - - name: Unit Testing run: phpunit env: diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 72f381a..7d30eb9 100755 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -29,7 +29,7 @@ require_once "{$_tests_dir}/includes/functions.php"; * Manually load the plugin being tested. */ function _manually_load_plugin() { - require dirname( dirname( __FILE__ ) ) . '/activitypub-event-extensions.php'; + require dirname( __DIR__ ) . '/activitypub-event-extensions.php'; } tests_add_filter( 'muplugins_loaded', '_manually_load_plugin' );