diff --git a/libraries/AP_Common/tests/test_fwversion.cpp b/libraries/AP_Common/tests/test_fwversion.cpp
index 18208ceb5e..e36f41fec3 100644
--- a/libraries/AP_Common/tests/test_fwversion.cpp
+++ b/libraries/AP_Common/tests/test_fwversion.cpp
@@ -1,5 +1,5 @@
 
-#define APM_BUILD_DIRECTORY 0
+#define APM_BUILD_DIRECTORY APM_BUILD_UNKNOWN
 
 #include <AP_gtest.h>
 #include <AP_Common/AP_FWVersion.h>