fix(ooniprobe): use ooniprobe-cli-unattended for unattended runs (#714)

This diff changes the software name used by unattended runs for which
we did not override the default software name (`ooniprobe-cli`).

It will become `ooniprobe-cli-unattended`. This software name is in line
with the one we use for Android, iOS, and desktop unattended runs.

While working in this diff, I introduced string constants for the run
types and a string constant for the default software name.

See https://github.com/ooni/probe/issues/2081.
This commit is contained in:
Simone Basso 2022-04-29 13:41:09 +02:00 committed by GitHub
commit d3c5196474
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 72 additions and 37 deletions

View file

@ -9,6 +9,7 @@ import (
"github.com/ooni/probe-cli/v3/cmd/ooniprobe/internal/database"
"github.com/ooni/probe-cli/v3/cmd/ooniprobe/internal/ooni"
"github.com/ooni/probe-cli/v3/internal/model"
)
func copyfile(source, dest string) error {
@ -45,7 +46,7 @@ func TestCreateContext(t *testing.T) {
func TestRun(t *testing.T) {
probe := newOONIProbe(t)
sess, err := probe.NewSession(context.Background())
sess, err := probe.NewSession(context.Background(), model.RunTypeManual)
if err != nil {
t.Fatal(err)
}