public void TestConvertPolicySetNullPolicySet()
		{
			LocalPolicyCache localPolicyCache = new LocalPolicyCache(m_testPath, false);
			IPolicySetCache policySetCache = localPolicyCache.NewPolicySet("Test policy set");
			PolicyConverterFactory policySetConverter = new PolicyConverterFactory(policySetCache);
			policySetConverter.ConvertPolicySet(AddConversionMessage);
		}
		public void TestGetPolicySetVersionNullPolicySet()
		{
			LocalPolicyCache localPolicyCache = new LocalPolicyCache(m_testPath, false);
			IPolicySetCache policySetCache = localPolicyCache.NewPolicySet("Test policy set");
			PolicyConverterFactory policySetConverter = new PolicyConverterFactory(policySetCache);
			policySetConverter.GetPolicySetVersion();
		}
 public void SetPolicy(string sPolicyFilePath, string sPolicyFileName)
 {
     m_sRememberPolicyName = sPolicyFileName;
     bool bRuntime = sPolicyFileName.EndsWith(".runtimepolicy", true, System.Globalization.CultureInfo.InvariantCulture);
     m_localCache = new LocalPolicyCache(sPolicyFilePath, bRuntime);
     m_localCache.NewPolicySet(sPolicyFileName);
     m_engine.PolicyCache = m_localCache;
 }
Пример #4
0
 public static IUroPolicyEngine CreateUroPolicyEngineWithPolicyCache(string policyDirectory)
 {
     UroPolicyEngine engine = new Workshare.Policy.Engine.UroPolicyEngine();
     LocalPolicyCache policyCache = new LocalPolicyCache(policyDirectory, true);
     policyCache.NewPolicySet(policyDirectory);
     engine.PolicyCache = policyCache;
     return engine;    
 }