diff --git a/README.md b/README.md index 6efdc7b5..4431c79d 100644 --- a/README.md +++ b/README.md @@ -71,7 +71,7 @@ make --always-make forgejo-runner cp forgejo-runner /tmp/forgejo-end-to-end/forgejo-runner ``` -## Running actions locally +## Running actions tests locally To run and debug workflows from `actions/example-*`, from the root of the source directory, with docker and forgejo-curl.sh installed, mimic @@ -92,6 +92,20 @@ firefox 0.0.0.0:3000 # user root / admin1234 Note that `with-docker-tcp` requires the docker daemon listens to tcp://127.0.0.1:2375. See `actions/actions.sh` for how to do that. +## Running federation tests locally + +To run and debug scenarios from `federation/*`, from the root of +the source directory, mimic what `.forgejo/workflows/end-to-end.yml` does. + +```sh +./end-to-end.sh run dependencies +./end-to-end.sh federation_setup 12.0 +firefox 0.0.0.0:3001 # user root / admin1234 +firefox 0.0.0.0:3002 # user root / admin1234 +./end-to-end.sh federation_verify_scenario star +./end-to-end.sh federation_teardown +``` + ## Running other tests locally To run and debug tests, from the root of the source directory. @@ -115,4 +129,3 @@ There is an included Dockerfile in which the tests can be run. Building the conatiner will copy the the entire repo state into the container from which changes to the tests can be tested. Note: running in podman requires the `--privileged` flag because this will run podman in podman for some tests. - diff --git a/federation/federation.sh b/federation/federation.sh index 0a841901..35a03f79 100755 --- a/federation/federation.sh +++ b/federation/federation.sh @@ -26,6 +26,8 @@ function federation_setup_variables() { function federation_verify_scenario() { local scenario=$1 + federation_setup_variables + export scenario export SCENARIO_DIR=$FEDERATION_DIR/scenario-$scenario