<commit_before>﻿using DeveImageOptimizer.Helpers;
using System;
using System.Collections.Generic;
using System.Text;
using Xunit;

namespace DeveImageOptimizer.Tests.Helpers
{    
    public class ValuesToStringHelperTests
    {
        [Fact]
        public void ConvertsBytesToMb()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(12345678L);

            //Assert
            Assert.Equal("11,8MB", result);
        }

        [Fact]
        public void ConvertsBytesToKb()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(1024L);

            //Assert
            Assert.Equal("1KB", result);
        }

        [Fact]
        public void Converts0BytesToB()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(0L);

            //Assert
            Assert.Equal("0B", result);
        }


        [Fact]
        public void ConvertsSecondsToHours()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(3800L);

            //Assert
            Assert.Equal("1,1 Hours", result);
        }

        [Fact]
        public void ConvertsSecondsToHours2()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(3600L);

            //Assert
            Assert.Equal("1 Hour", result);
        }

        [Fact]
        public void ConvertsSecondsToMinutes()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(120L);

            //Assert
            Assert.Equal("2 Minutes", result);
        }

        [Fact]
        public void Converts0SecondsToSeconds()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(0L);

            //Assert
            Assert.Equal("0 Seconds", result);
        }
    }
}<commit_msg>Made tests culture invarriant<commit_after>﻿using DeveImageOptimizer.Helpers;
using System;
using System.Collections.Generic;
using System.Text;
using Xunit;

namespace DeveImageOptimizer.Tests.Helpers
{    
    public class ValuesToStringHelperTests
    {
        [Fact]
        public void ConvertsBytesToMb()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(12345678L).Replace('.', ',');

            //Assert
            Assert.Equal("11,8MB", result);
        }

        [Fact]
        public void ConvertsBytesToKb()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(1024L).Replace('.', ',');

            //Assert
            Assert.Equal("1KB", result);
        }

        [Fact]
        public void Converts0BytesToB()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.BytesToString(0L).Replace('.', ',');

            //Assert
            Assert.Equal("0B", result);
        }


        [Fact]
        public void ConvertsSecondsToHours()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(3800L).Replace('.', ',');

            //Assert
            Assert.Equal("1,1 Hours", result);
        }

        [Fact]
        public void ConvertsSecondsToHours2()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(3600L).Replace('.', ',');

            //Assert
            Assert.Equal("1 Hour", result);
        }

        [Fact]
        public void ConvertsSecondsToMinutes()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(120L).Replace('.', ',');

            //Assert
            Assert.Equal("2 Minutes", result);
        }

        [Fact]
        public void Converts0SecondsToSeconds()
        {
            //Arrange

            //Act
            var result = ValuesToStringHelper.SecondsToString(0L).Replace('.', ',');

            //Assert
            Assert.Equal("0 Seconds", result);
        }
    }
}
{'fraction_non_alphanumeric': 0.10621147463252727, 'fraction_numerical': 0.018018018018018018, 'mean_word_length': 1.3876627051499717, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5394381', 'n_tokens_mistral': 1161, 'n_tokens_neox': 1069, 'n_words': 209}