Fix script tests to work