From d414f8b7720913d260ae3c90321bb3c433324748 Mon Sep 17 00:00:00 2001
From: Stephan Schulz <stephan.schulz-x2q@ruhr-uni-bochum.de>
Date: Mon, 9 Aug 2021 13:00:53 +0200
Subject: [PATCH] Throw error if feature tests without Fortran are used

---
 tests/CMakeLists.txt | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 68f5bca..44f4fc4 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,5 +1,8 @@
 add_subdirectory(unit)
 if(CM_ALL_TESTS_INTEGRATION)
+    if(NOT CM_ALL_FORTRAN)
+        message(FATAL_ERROR "Feature tests are only available if Fortran is enabled as well")
+    endif()
     add_subdirectory(feature)
 endif()
 if(CM_ALL_FORTRAN)
-- 
GitLab