Il 24/01/2014 18:04, Lucas Meneghel Rodrigues ha scritto:
Taking the provider definitions out of the version control systems
allows for this workflow:

1) You clone virt-test, bootstrap, it'll download the specified version
of the git repos defined in test-providers.d. So far, no changes from
submodules
2) If we're referencing master, we won't update the test provider until
you provide --update-providers flag. If you do, it'll be updated, and
*you don't have to mess with git commands*.

This is also the same with submodules, the "git submodule update" can be run by virt-test not necessarily by the user.

If you had the submodules, they point out to a specific commit of that
submodule. So, to keep track of master, you have to manually go inside
the tree, update your submodule and commit the change.

The inconvenience is true, but the corresponding advantage is reproducibility of results. Whenever you'll change the API for say guest-hw.cfg, and this affects some "only" or "no" statement in the test providers' own .cfg files, you will not be able to associate which versions of tp-* will work with which versions of virt-tests.

This means you have to do a lot of house keeping by yourself. I must say
since virt-test.git became a submodule of autotest-client-tests.git, and
autotest-client-tests.git became a submodule of autotest.git, I feel
depressed every time I make a virt-test release and have to remember to
update the chain of references on the other repos higher up the stack.
But that may just be me being a less than competent maintainer.

It is indeed a chore.

Also, with test providers you can use non-git resources (say, you have a
bunch of tests under /usr/share/tests), which is more flexible than
having to create a git repo, and a new commit referencing that git repo.

That can be useful I guess.

Hypothetically, the two files currently in test-providers.d would be
replaced by a .gitmodules file like this one:

[submodule "qemu"]
     path = test-providers/qemu
     url = https://github.com/autotest/tp-qemu.git
     subdirs = generic/ qemu/ openvswitch/

^ I did not know git submodules supported subdirs.

They don't, but you can add arbitrary keys to the .gitmodules file.

I believe it is fine using git submodules + test providers, should the
need arise.

Is there documentation for how to "initialize" the provider
repositories?  Will "./run -t qemu" do just that?

I did write the rough specification of how a test provider looks like here:

I'm more interested in how to use it (docs for --update-providers etc.)...

_______________________________________________
Virt-test-devel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/virt-test-devel

Reply via email to