On Fri, Jul 2, 2021 at 8:40 AM Cleber Rosa <crosa(a)redhat.com> wrote:
There are a couple of ways. The simplest is hinting to Avocado that a
file is of kind "tap" with a hintfile. Suppose you have a
"test-suite" directory, and in it, you have "test.sh":
#!/bin/sh -e
echo "1..2"
echo "ok 2 /bin/true"
echo "ok 3 /bin/uname"
And ".avocado.hint":
[kinds]
tap = *.sh
[tap]
uri = $testpath
If you "cd test-suite", and do "avocado list --resolver *sh" you get:
Actually, I ran the verbose version, that is, ""avocado -V list --resolver
*sh".
Type Test Tag(s)
tap test.sh
Resolver Reference Info
TEST TYPES SUMMARY
==================
tap: 1
And then you can run it with:
$ avocado run --test-runner=nrunner ./test.sh
JOB ID : 2166ad93ffc25da4d5fc8e7db073f4555d55e81a
JOB LOG : /home/cleber/avocado/job-results/job-2021-07-02T08.39-2166ad9/job.log
(1/1) ./test.sh: STARTED
(1/1) ./test.sh: PASS (0.01 s)
RESULTS : PASS 1 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0
| CANCEL 0
JOB HTML : /home/cleber/avocado/job-results/job-2021-07-02T08.39-2166ad9/results.html
JOB TIME : 1.31 s
This is a relevant documentation pointer:
https://avocado-framework.readthedocs.io/en/latest/guides/user/chapters/i...
And I'll make sure the man page is updated, thanks for noticing it.
Thanks,
- Cleber.
> Regards,
> Daniel
> --
> |:
https://berrange.com -o-
https://www.flickr.com/photos/dberrange :|
> |:
https://libvirt.org -o-
https://fstop138.berrange.com :|
> |:
https://entangle-photo.org -o-
https://www.instagram.com/dberrange :|
>