tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

mixerctl with no args

I noticed that the b5 mixerctl tests fail - seems to be because the
qemu kernel the tests are run under has no audio (and hence any open
of /dev/mixer* fails).   That's fine, and I can (and am in the process
of) cause the tests that will fail to simply be skipped when running
under qemu.

But one of the tests just runs
and expects to see the usage message.   In a "normal" system that's
what happens, but it only happens after /dev/mixer (or whatever) has
been opened - which fails under qemu, causing the test to fail.

Is the general feeling that this is OK, and this test (which doesn't really
need the mixer at all) should also be skipped on qemu, or should mixerctl
be fixed to detect this case and give the usage without attempting to
open the mixer device?

Note that the latter is not quite as simple as it seems, as "no args"
to generate a usage also includes cases like
	mixerctl -d /dev/mixer2
	mixerctl -n
where there are args given, but none that result in mixerctl doing anything,
so we still get a usage (provided the device can be opened in the -d case).

It would be easy to handle just the no args at all case (which would
satisfy the ATF test) but that seems a bit wonky to me.



Home | Main Index | Thread Index | Old Index