test: Disable test if it is used as subproject

This prevent other projects that depends on this to run its tests. These
tests are not guarantee to work as subproject.

Change-Id: I0743266211427e1ce20f3f8ae4ec241fd284eb7c
Signed-off-by: Willy Tu <wltu@google.com>
diff --git a/meson.build b/meson.build
index 85ffb79..dc88a95 100644
--- a/meson.build
+++ b/meson.build
@@ -9,6 +9,7 @@
     'cpp_std=c++20',
     'werror=true',
     'warning_level=3',
+    'tests=' + (meson.is_subproject() ? 'disabled' : 'auto'),
   ])
 
 libbej_incs = include_directories('include')