<commit_before>using System;
using Amazon;
using Amazon.Runtime.CredentialManagement;
using FluentAssertions;
using Paramore.Brighter.MessagingGateway.AWSSQS;
using Paramore.Brighter.Tests.CommandProcessors.TestDoubles;
using Xunit;

namespace Paramore.Brighter.Tests.MessagingGateway.AWSSQS
{
    public class SQSBufferedConsumerTests
    {
        private readonly SqsMessageProducer _messageProducer;
        private SqsMessageConsumer _consumer;
        private readonly string _topicName = Guid.NewGuid().ToString().ToValidSNSTopicName();
        private const string CONTENT_TYPE = "text\\plain";
        private const int BUFFER_SIZE = 3;
        private const int MESSAGE_COUNT = 4;

        public SQSBufferedConsumerTests()
        {
            //Must have credentials stored in the SDK Credentials store or shared credentials file
            if (new CredentialProfileStoreChain().TryGetAWSCredentials("default", out var credentials))
            {
                var awsConnection = new AWSMessagingGatewayConnection(credentials, RegionEndpoint.EUWest1);

                ChannelFactory channelFactory = new ChannelFactory(awsConnection, new SqsMessageConsumerFactory(awsConnection));
                var name = Guid.NewGuid().ToString();
                
                //we need the channel to create the queues and notifications
                channelFactory.CreateChannel(new Connection<MyCommand>(
                    name: new ConnectionName(name),
                    channelName:new ChannelName(name),
                    routingKey:new RoutingKey(_topicName),<commit_msg>Adds missing AWS category from tests<commit_after>﻿using System;
using Amazon;
using Amazon.Runtime.CredentialManagement;
using FluentAssertions;
using Paramore.Brighter.MessagingGateway.AWSSQS;
using Paramore.Brighter.Tests.CommandProcessors.TestDoubles;
using Xunit;

namespace Paramore.Brighter.Tests.MessagingGateway.AWSSQS
{
    [Collection("AWS")]
    [Trait("Category", "AWS")]
    public class SQSBufferedConsumerTests
    {
        private readonly SqsMessageProducer _messageProducer;
        private SqsMessageConsumer _consumer;
        private readonly string _topicName = Guid.NewGuid().ToString().ToValidSNSTopicName();
        private const string CONTENT_TYPE = "text\\plain";
        private const int BUFFER_SIZE = 3;
        private const int MESSAGE_COUNT = 4;

        public SQSBufferedConsumerTests()
        {
            //Must have credentials stored in the SDK Credentials store or shared credentials file
            if (new CredentialProfileStoreChain().TryGetAWSCredentials("default", out var credentials))
            {
                var awsConnection = new AWSMessagingGatewayConnection(credentials, RegionEndpoint.EUWest1);

                ChannelFactory channelFactory = new ChannelFactory(awsConnection, new SqsMessageConsumerFactory(awsConnection));
                var name = Guid.NewGuid().ToString();
                
                //we need the channel to create the queues and notifications
                channelFactory.CreateChannel(new Connection<MyCommand>(
                    name: new ConnectionName(name),
                    channelName:new ChannelName(name),
                    routingKey:new RoutingKey(_topicName),
{'fraction_non_alphanumeric': 0.0684805869764598, 'fraction_numerical': 0.0018343014368694588, 'mean_word_length': 2.9564691656590085, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7156263', 'n_tokens_mistral': 830, 'n_tokens_neox': 793, 'n_words': 207}