fix(go-build-alpine): honour OONI_PSIPHON_TAGS (#968)
Closes https://github.com/ooni/probe/issues/2334. While there, reinstate integration tests, which were also lost in a previous refactoring. However, only run those tests for linux/amd64 because we can be confident that the Go compiler is WAI for all archs we support. While there, always use bash for running end-to-end tests. H/T @ainghazal for discovering and reporting this bug.
This commit is contained in:
parent
2cfc3325db
commit
89a584f93b
10 changed files with 57 additions and 31 deletions
|
|
@ -1,9 +1,10 @@
|
|||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
# This script checks whether we can install ooniprobe on debian
|
||||
# for a specific architecture using docker and the official
|
||||
# install instructions published at https://ooni.org/install.
|
||||
|
||||
set -e
|
||||
set -euo pipefail
|
||||
|
||||
install_flow() {
|
||||
set -x
|
||||
|
|
@ -26,7 +27,7 @@ docker_flow() {
|
|||
}
|
||||
set -x
|
||||
docker pull debian:stable
|
||||
docker run -v "$(pwd):/ooni" -w /ooni debian:stable ./E2E/debian.sh install "$1"
|
||||
docker run -v "$(pwd):/ooni" -w /ooni debian:stable ./E2E/debian.bash install "$1"
|
||||
}
|
||||
|
||||
if [ "$1" = "docker" ]; then
|
||||
|
|
@ -1,23 +1,26 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
|
||||
# This script checks whether we're able to submit measurements to
|
||||
# different backends using miniooni. It fails if we cannot find in
|
||||
# the specific backend the measurement we submitted.
|
||||
#
|
||||
set -e
|
||||
# Note: using --tunnel=psiphon assumes that we have been compiling
|
||||
# miniooni with builtin support for psiphon.
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
backends=()
|
||||
backends+=( "https://api.ooni.io" )
|
||||
backends+=( "https://dvp6h0xblpcqp.cloudfront.net" )
|
||||
backends+=( "https://ams-pg-test.ooni.org" )
|
||||
|
||||
miniooni="${1:-./miniooni}"
|
||||
for ps in ${backends[@]}; do
|
||||
opt="-o E2E/o.jsonl --probe-services=$ps"
|
||||
set -x
|
||||
$miniooni --yes $opt -i http://mail.google.com web_connectivity
|
||||
$miniooni --yes $opt tor
|
||||
$miniooni --yes $opt psiphon
|
||||
set +x
|
||||
done
|
||||
set -x
|
||||
go run ./internal/cmd/e2epostprocess -expected 9
|
||||
set +x
|
||||
|
||||
$miniooni --tunnel=psiphon --yes -i http://mail.google.com web_connectivity
|
||||
$miniooni --tunnel=tor --yes -i http://mail.google.com web_connectivity
|
||||
|
||||
#go run ./internal/cmd/e2epostprocess -expected 5 # TODO(bassosimone): fix this
|
||||
|
|
|
|||
|
|
@ -1,16 +1,19 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
#!/bin/bash
|
||||
|
||||
# This test for now uses --no-collector and we just ensure that the OONI
|
||||
# instance is not exploding. We are confident that, if miniooni submits
|
||||
# measurements, also ooniprobe should be able to do that. However, it would
|
||||
# actually be nice if someone could enhance this script to also make sure
|
||||
# that we can actually fetch the measurements we submit.
|
||||
#
|
||||
set -ex
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
if [ "$#" != 1 ]; then
|
||||
echo "Usage: $0 <binary>" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
$1 onboard --yes
|
||||
|
||||
# Important! DO NOT run performance from CI b/c it will overload m-lab servers
|
||||
$1 run websites --config cmd/ooniprobe/testdata/testing-config.json --no-collector
|
||||
Loading…
Reference in a new issue