Mercurial > hg > orthanc
comparison UnitTestsSources/PluginsTests.cpp @ 1578:09715095fc53
cont
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 25 Aug 2015 15:33:36 +0200 |
parents | f967bdf8534e |
children | b1291df2f780 |
comparison
equal
deleted
inserted
replaced
1577:7aac0cddd42e | 1578:09715095fc53 |
---|---|
35 | 35 |
36 #include "../Plugins/Engine/PluginsManager.h" | 36 #include "../Plugins/Engine/PluginsManager.h" |
37 | 37 |
38 using namespace Orthanc; | 38 using namespace Orthanc; |
39 | 39 |
40 | |
41 #if ORTHANC_PLUGINS_ENABLED == 1 | |
42 | |
43 TEST(SharedLibrary, Enumerations) | |
44 { | |
45 // The plugin engine cannot work if the size of an enumeration does | |
46 // not correspond to the size of "int32_t" | |
47 ASSERT_EQ(sizeof(int32_t), sizeof(OrthancPluginErrorCode)); | |
48 } | |
49 | |
50 | |
40 TEST(SharedLibrary, Basic) | 51 TEST(SharedLibrary, Basic) |
41 { | 52 { |
42 #if defined(_WIN32) | 53 #if defined(_WIN32) |
43 SharedLibrary l("kernel32.dll"); | 54 SharedLibrary l("kernel32.dll"); |
44 ASSERT_THROW(l.GetFunction("world"), OrthancException); | 55 ASSERT_THROW(l.GetFunction("world"), OrthancException); |
72 | 83 |
73 #else | 84 #else |
74 #error Support your platform here | 85 #error Support your platform here |
75 #endif | 86 #endif |
76 } | 87 } |
88 | |
89 #endif |