summaryrefslogtreecommitdiffstats
path: root/test/build_test.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-07-18 10:55:20 +0200
committerDavid Robillard <d@drobilla.net>2020-07-18 10:55:20 +0200
commit301fcab43e6420977e0de95b10f33d24b16e9535 (patch)
treed5b915bf036903b1de35d1b3c53c2c8756026ea1 /test/build_test.cpp
parent242bbeb5649b62a9af4268139afe6f57250520e0 (diff)
downloadraul-301fcab43e6420977e0de95b10f33d24b16e9535.tar.gz
raul-301fcab43e6420977e0de95b10f33d24b16e9535.tar.bz2
raul-301fcab43e6420977e0de95b10f33d24b16e9535.zip
Use everything in build test
Annoyingly, include-what-you-use does not have a suppression mechanism, so minimally use everything in the build test to avoid include warnings.
Diffstat (limited to 'test/build_test.cpp')
-rw-r--r--test/build_test.cpp51
1 files changed, 49 insertions, 2 deletions
diff --git a/test/build_test.cpp b/test/build_test.cpp
index cbf153d..31b133a 100644
--- a/test/build_test.cpp
+++ b/test/build_test.cpp
@@ -28,12 +28,59 @@
#include "raul/TimeStamp.hpp"
#ifndef _WIN32
-#include "raul/Process.hpp"
-#include "raul/Socket.hpp"
+# include "raul/Process.hpp"
+# include "raul/Socket.hpp"
#endif
+class DeletableThing : public Raul::Deletable
+{
+};
+
+class NonCopyableThing : public Raul::Noncopyable
+{
+};
+
int
main()
{
+ Raul::Array<int> array;
+ DeletableThing deletable;
+ Raul::DoubleBuffer<int> double_buffer(0);
+ Raul::Maid maid;
+ NonCopyableThing non_copyable;
+ Raul::Path path;
+ Raul::RingBuffer ring_buffer(64u);
+ Raul::Semaphore semaphore(0u);
+ Raul::Symbol symbol("foo");
+ Raul::TimeSlice time_slice(48000u, 960u, 120.0);
+
+ Raul::TimeStamp time_stamp(Raul::TimeUnit(Raul::TimeUnit::BEATS, 960u));
+
+ try {
+ Raul::Symbol bad_symbol("not a valid symbol!");
+ (void)bad_symbol;
+ } catch (const Raul::Exception&) {
+ }
+
+#ifndef _WIN32
+ const char* cmd[] = {"echo"};
+ Raul::Process::launch(cmd);
+
+ Raul::Socket socket(Raul::Socket::Type::UNIX);
+
+ (void)socket;
+#endif
+
+ (void)array;
+ (void)deletable;
+ (void)double_buffer;
+ (void)maid;
+ (void)non_copyable;
+ (void)path;
+ (void)ring_buffer;
+ (void)symbol;
+ (void)time_slice;
+ (void)time_stamp;
+
return 0;
}