test is run as a script and when imported via the regression test framework. Problem reported by Phillip Porch <root@theporch.com>.