--- a/installationservices/swi/test/swicaptests/registrycaptest.cpp Tue Jul 06 14:23:31 2010 +0300
+++ b/installationservices/swi/test/swicaptests/registrycaptest.cpp Wed Aug 18 09:55:45 2010 +0300
@@ -53,6 +53,7 @@
_LIT(KRevocationRegistryCapTestName, "Registry revocation interface capability test");
#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
_LIT(KSifServerRegistryCapTestName, "Registry SIF interface security test");
+_LIT(KSisRegistryTCBCapTestName, "Sis Registry interface requiring TCB security test");
#endif
CPublicRegistryCapTest* CPublicRegistryCapTest::NewL()
@@ -607,6 +608,47 @@
CleanupStack::PopAndDestroy(&session);
}
+
+CSisRegistryTCBCapTest* CSisRegistryTCBCapTest::NewL()
+ {
+ CSisRegistryTCBCapTest* self=new(ELeave) CSisRegistryTCBCapTest();
+ CleanupStack::PushL(self);
+ self->ConstructL();
+ CleanupStack::Pop(self);
+ return self;
+ }
+
+CSisRegistryTCBCapTest::CSisRegistryTCBCapTest()
+ {
+ SetCapabilityRequired(ECapabilityTCB); //API requires TCB capability, so giving it
+ }
+
+void CSisRegistryTCBCapTest::ConstructL()
+ {
+ SetNameL(KSisRegistryTCBCapTestName);
+ }
+
+void CSisRegistryTCBCapTest::RunTestL()
+ {
+ Swi::RSisRegistrySession registrySession;
+ CleanupClosePushL(registrySession);
+ _LIT(regFileName,"c:\\private\\10003a3f\\import\\apps\\dummy_reg.rsc");
+ TInt err = registrySession.Connect();
+ if (KErrNone != err)
+ {
+ SetFail();
+ CleanupStack::PopAndDestroy(®istrySession);
+ return;
+ }
+
+ TRAP(err, registrySession.AddAppRegInfoL(regFileName));
+ CheckFailL(err, _L("AddAppRegInfoL"));
+
+ TRAP(err, registrySession.RemoveAppRegInfoL(regFileName));
+ CheckFailL(err, _L("RemoveAppRegInfoL"));
+
+ CleanupStack::PopAndDestroy(®istrySession);
+ }
#endif