| 214 | #endif |
| 215 | |
| 216 | TEST(StaticBundleTest, testStaticBundle) |
| 217 | { |
| 218 | FrameworkFactory factory; |
| 219 | FrameworkConfiguration frameworkConfig; |
| 220 | auto framework = factory.NewFramework(frameworkConfig); |
| 221 | framework.Start(); |
| 222 | |
| 223 | auto context = framework.GetBundleContext(); |
| 224 | |
| 225 | { // scope the use of the listener so its destructor is |
| 226 | // called before we destroy the framework's bundle context. |
| 227 | // The TestBundleListener needs to remove its listeners while |
| 228 | // the framework is still active. |
| 229 | TestBundleListener listener; |
| 230 | |
| 231 | BundleListenerRegistrationHelper<TestBundleListener> ml(context, |
| 232 | &listener, |
| 233 | &TestBundleListener::BundleChanged); |
| 234 | ServiceListenerRegistrationHelper<TestBundleListener> sl(context, |
| 235 | &listener, |
| 236 | &TestBundleListener::ServiceChanged); |
| 237 | |
| 238 | frame020a(context, listener); |
| 239 | frame030b(context, listener); |
| 240 | #ifdef US_BUILD_SHARED_LIBS |
| 241 | // bundles in the executable are auto-installed. |
| 242 | // install and uninstall on embedded bundles is not allowed. |
| 243 | frame040c(context, listener); |
| 244 | #endif |
| 245 | } |
| 246 | } |
| 247 | } // namespace |
| 248 | |
| 249 | US_MSVC_POP_WARNING |
nothing calls this directly
no test coverage detected