示例#1
0
        public void Filter()
        {
            var filter = Guid.NewGuid().ToString();
            var s      = new BusTopicSubscription(Guid.NewGuid().ToString(), connection, Guid.NewGuid().ToString(), filter);

            Assert.AreEqual(filter, s.Filter);
        }
示例#2
0
        public void TopicName()
        {
            var name = Guid.NewGuid().ToString();
            var s    = new BusTopicSubscription(name, connection, Guid.NewGuid().ToString());

            Assert.AreEqual(name, s.TopicName);
        }
        public async Task Delete()
        {
            var s = new BusTopicSubscription(name, Configuration.ConnectionString, "subsciption");
            var c = await s.CreateIfNotExists();

            await s.Delete();
        }
        public async Task CreateIfNotExistsWithFilter()
        {
            var s = new BusTopicSubscription(name, Configuration.ConnectionString, "subsciption", "MesageId > 100");
            var c = await s.CreateIfNotExists();

            Assert.IsTrue(c);
        }
示例#5
0
        public void Setup()
        {
            var random = new Random();

            name = string.Format("a{0}b", random.Next());

            topic = new BusTopic(name, connection);
            topic.CreateIfNotExists().Wait();

            var s = new BusTopicSubscription(topic.Name, connection, "testing");

            s.CreateIfNotExists().Wait();
        }
示例#6
0
        public void FilterWhiteSpace()
        {
            var s = new BusTopicSubscription(Guid.NewGuid().ToString(), connection, Guid.NewGuid().ToString(), "   ");

            Assert.IsNull(s.Filter);
        }