示例#1
0
        public void given_a_messaging_factory()
        {
            mf = TestConfigFactory.CreateMessagingFactory();
            var nm = TestConfigFactory.CreateNamespaceManager(mf);

            nm.TopicExists("my.topic.here").ShouldBeFalse();
        }
示例#2
0
 public void it_exists_afterwards()
 {
     TestConfigFactory.CreateNamespaceManager(TestConfigFactory.CreateMessagingFactory())
     .ExistsAsync(address.QueueDescription)
     .Result
     .ShouldBeTrue();
 }
示例#3
0
        public void theres_a_namespace_manager_available()
        {
            var mf = TestConfigFactory.CreateMessagingFactory();

            nm = TestConfigFactory.CreateNamespaceManager(mf);

            _formatter = new AzureServiceBusMessageNameFormatter();
        }
示例#4
0
        public void nsm_mf_and_topic()
        {
            var tp = TestConfigFactory.CreateTokenProvider();
            var mf = TestConfigFactory.CreateMessagingFactory(tp);
            var nm = TestConfigFactory.CreateNamespaceManager(mf, tp);

            topic = nm.TryCreateTopic(mf, "sample-topic").Result;
            topic.ShouldNotBeNull();
        }
示例#5
0
        public void when_I_place_a_message_in_the_queue()
        {
            message = TestDataFactory.AMessage();
            var mf = TestConfigFactory.CreateMessagingFactory();

            nm = TestConfigFactory.CreateNamespaceManager(mf);
            nm.TryCreateQueue("test-queue").Wait();
            t = mf.CreateQueueClient("test-queue");
            t.Send(new BrokeredMessage(message));
        }
示例#6
0
        public void nsm_mf_and_topic()
        {
            var tp = TestConfigFactory.CreateTokenProvider();
            var mf = TestConfigFactory.CreateMessagingFactory(tp);

            desc = new QueueDescriptionImpl("to-be-drained");
            nm   = TestConfigFactory.CreateNamespaceManager(mf, tp);

            client = mf.NewSenderAsync(nm, desc).Result;

            // sanity checks; I can now place a message in the queue
            client.Send(new BrokeredMessage(new A("My Contents", new byte[] { 1, 2, 3 })));
        }
示例#7
0
        public void theres_a_namespace_manager_available()
        {
            var mf = TestConfigFactory.CreateMessagingFactory();

            nm = TestConfigFactory.CreateNamespaceManager(mf);
        }