当前位置: 首页>>代码示例>>C#>>正文


C# Loader.GetUserGroups方法代码示例

本文整理汇总了C#中Loader.GetUserGroups方法的典型用法代码示例。如果您正苦于以下问题:C# Loader.GetUserGroups方法的具体用法?C# Loader.GetUserGroups怎么用?C# Loader.GetUserGroups使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Loader的用法示例。


在下文中一共展示了Loader.GetUserGroups方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: As_an_unknown_skype_user_I_want_to_have_an_error_message_when_configuration_is_loaded

 public void As_an_unknown_skype_user_I_want_to_have_an_error_message_when_configuration_is_loaded()
 {
     var skype = new Skype(makeMessageProcessor());
     var chats = new Chats(skype);
     var configurationLoader = new ConfigurationLoader();
     var loader = new Loader(new MessengerClient(skype, new UserCollection(new SKYPE4COMLib.UserCollection()), chats),new BuildCollection());
     Assert.Throws<UserNotKnowException>(() => loader.GetUserGroups(configurationLoader.Load("UnknownUserPipeline.xml")));
 }
开发者ID:perryofpeek,项目名称:CCSkype,代码行数:8,代码来源:End_To_End_Tests.cs

示例2: As_A_user_I_want_to_have_a_message_when_a_build_fails_so_that_I_can_fix_the_build

        public void As_A_user_I_want_to_have_a_message_when_a_build_fails_so_that_I_can_fix_the_build()
        {
            var message = "someMessage - " + Guid.NewGuid().ToString();
            var skype = new Skype(makeMessageProcessor());
            var chats = new Chats(skype);
            var configurationLoader = new ConfigurationLoader();
            var loader = new Loader(new MessengerClient(skype, new UserCollection(new SKYPE4COMLib.UserCollection()), chats), new BuildCollection());
            var projectwatcher = new Projectwatcher(loader.GetUserGroups(configurationLoader.Load("OnePipeline.xml")));

            string url = "someUrl";

            var httpGet = MockRepository.GenerateMock<IHttpGet>();
            httpGet.Expect(x => x.Request(url));
            httpGet.Expect(x => x.StatusCode).Return(200);
            httpGet.Expect(x => x.ResponseBody).Return(File.ReadAllText("cctray.xml"));

            ICcTray ccTray = new CcTray(new EndpointImpl(httpGet, url));
            ccTray.Load();

            //Test
            projectwatcher.Message(ccTray.FailedPipelines());
        }
开发者ID:perryofpeek,项目名称:CCSkype,代码行数:22,代码来源:End_To_End_Tests.cs

示例3: Skype

        public void As_A_user_I_want_to_two_messages_in_the_same_group_window_when_a_build_fails_so_that_I_can_fix_the_builds_when_each_fails()
        {
            var skype = new Skype(makeMessageProcessor());
            var chats = new Chats(skype);
            var configurationLoader = new ConfigurationLoader();
            var loader = new Loader(new MessengerClient(skype, new UserCollection(new SKYPE4COMLib.UserCollection()), chats),new BuildCollection());
            var projectwatcher = new Projectwatcher(loader.GetUserGroups(configurationLoader.Load("OnePipeline.xml")));

            string url = "someUrl";

            var httpGet = MockRepository.GenerateMock<IHttpGet>();
            httpGet.Expect(x => x.Request(url));
            httpGet.Expect(x => x.StatusCode).Return(200);
            httpGet.Expect(x => x.ResponseBody).Return(File.ReadAllText("cctray.xml"));

            ICcTray ccTray = new CcTray(new EndpointImpl(httpGet, url));
            ccTray.Load();

            //Test
            projectwatcher.Message(ccTray.FailedPipelines());

            var p = new Project("Trunk_QA_Env_PCIDSS :: Deployment_to_QA_PCIDSS1", "Failed", "Failure", "1.2.3.4","2011-09-23T16:59:18", "web");
            ccTray.FailedPipelines().Add(p);
            projectwatcher.Message(ccTray.FailedPipelines());

            projectwatcher.Message(ccTray.FailedPipelines());
        }
开发者ID:perryofpeek,项目名称:CCSkype,代码行数:27,代码来源:End_To_End_Tests.cs


注:本文中的Loader.GetUserGroups方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。