Example #1
0
        public void Invalid_topic_name_without_group()
        {
            var name  = "Invalid";
            var query = new TopicByName(connectionString);

            query.Exists(name, null).Should().Be.False();

            var result = query.Get(name, null);

            Assert.IsNull(result);
        }
Example #2
0
        public void Correct_topic_name_in_invalid_group()
        {
            var groupId = Identity.Random(12);
            var query   = new TopicByName(connectionString);

            query.Exists(topicInGroup.Name, groupId).Should().Be.False();

            var result = query.Get(topicInGroup.Name, groupId);

            Assert.IsNull(result);
        }
Example #3
0
        public void Invalid_topic_name_with_group()
        {
            var name    = "Invalid";
            var groupId = Identity.Random(12);
            var query   = new TopicByName(connectionString);

            query.Exists(name, groupId).Should().Be.False();

            var result = query.Get(name, groupId);

            Assert.IsNull(result);
        }
Example #4
0
        public void Correct_topic_name_without_group()
        {
            var query = new TopicByName(connectionString);

            query.Exists(topicWithoutGroup.Name, null).Should().Be.True();

            var result = query.Get(topicWithoutGroup.Name, null);

            Assert.IsNotNull(result);
            Assert.AreEqual(topicWithoutGroup.Id, result.Id);
            Assert.AreEqual(topicWithoutGroup.Name, result.Name);
            Assert.IsNull(result.GroupId);
        }
 public SNSPublisher(IAmazonSimpleNotificationService amazonSNSClient, TopicByName toicByName) :
     this(amazonSNSClient, new TopicConfiguration(amazonSNSClient, toicByName))
 {
 }