fix version check in test_dir