Skip to content
This repository has been archived by the owner on Jan 6, 2024. It is now read-only.

Commit

Permalink
resolves #29
Browse files Browse the repository at this point in the history
  • Loading branch information
sphildreth committed Nov 4, 2019
1 parent cb37aab commit f385c8f
Show file tree
Hide file tree
Showing 44 changed files with 1,085 additions and 636 deletions.
2 changes: 1 addition & 1 deletion Roadie.Api.Library.Tests/ConfigurationTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public ConfigurationTests()
}

[Fact]
public void Load_Root_Level_Configuration()
public void LoadRootLevelConfiguration()
{
var inboundFolder = @"C:\roadie_dev_root\inbound";
var configInboundFolder = this.Settings.InboundFolder;
Expand Down
2 changes: 1 addition & 1 deletion Roadie.Api.Library.Tests/EncryptionHelperTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace Roadie.Library.Tests
public class EncryptionHelperTests
{
[Fact]
public void Encrypt_And_Decrypt()
public void EncryptAndDecrypt()
{
var key = Guid.NewGuid().ToString();
var value = Guid.NewGuid().ToString();
Expand Down
16 changes: 8 additions & 8 deletions Roadie.Api.Library.Tests/ExtensionTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public class ExtensionTests
{

[Fact]
public void Shuffle_Unique_Order()
public void ShuffleUniqueOrder()
{
var tracks = new List<Roadie.Library.Models.TrackList>
{
Expand Down Expand Up @@ -225,12 +225,12 @@ public void Shuffle_Unique_Order()
lastTrack = track;
}

Assert.Equal(tracks.Count(), shuffledTracks.Count());
Assert.Equal(tracks.Count, shuffledTracks.Count());
}


[Fact]
public void From_Unix_Time()
public void FromUnixTime()
{
var dateTime = new DateTime(2015, 05, 24, 10, 2, 0, DateTimeKind.Utc);
var epoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
Expand All @@ -240,7 +240,7 @@ public void From_Unix_Time()
}

[Fact]
public void To_Unix_Time()
public void ToUnixTime()
{
var dateTime = new DateTime(2015, 05, 24, 10, 2, 0, DateTimeKind.Utc);
var epoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
Expand All @@ -254,14 +254,14 @@ public void To_Unix_Time()
[InlineData(150, 0)]
[InlineData(65000, 65)]
[InlineData(143000, 143)]
public void To_Seconds_From_Milliseconds_Decimal(int input, int shouldBe)
public void ToSecondsFromMillisecondsDecimal(int input, int shouldBe)
{
var d = ((decimal?)input).ToSecondsFromMilliseconds();
Assert.Equal(shouldBe, d);
}

[Fact]
public void To_Time_Span()
public void ToTimeSpan()
{
var dateTime = new DateTime(2015, 05, 24, 10, 2, 0, DateTimeKind.Utc);
var epoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
Expand All @@ -273,7 +273,7 @@ public void To_Time_Span()
}

[Fact]
public void Or_Integers()
public void OrIntegers()
{
int? test = null;
int? shouldBe = 5;
Expand All @@ -285,7 +285,7 @@ public void Or_Integers()
[InlineData(150, 0)]
[InlineData(65000, 65)]
[InlineData(143000, 143)]
public void To_Seconds_From_Milliseconds_Int(int? input, int? shouldBe)
public void ToSecondsFromMillisecondsInt(int? input, int? shouldBe)
{
var d = input.ToSecondsFromMilliseconds();
Assert.Equal(shouldBe, d);
Expand Down
30 changes: 15 additions & 15 deletions Roadie.Api.Library.Tests/ID3TagsHelperTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ private ILogger Logger
public ID3TagsHelperTests()
{
this.MessageLogger = new EventMessageLogger<ID3TagsHelperTests>();
this.MessageLogger.Messages += MessageLogger_Messages;
this.MessageLogger.Messages += MessageLoggerMessages;

var settings = new RoadieSettings();
IConfigurationBuilder configurationBuilder = new ConfigurationBuilder();
Expand All @@ -43,11 +43,11 @@ public ID3TagsHelperTests()
this.Configuration = settings;
this.CacheManager = new DictionaryCacheManager(this.Logger, new CachePolicy(TimeSpan.FromHours(4)));
var tagHelperLooper = new EventMessageLogger<ID3TagsHelper>();
tagHelperLooper.Messages += MessageLogger_Messages;
tagHelperLooper.Messages += MessageLoggerMessages;
this.TagsHelper = new ID3TagsHelper(this.Configuration, this.CacheManager, tagHelperLooper);
}

private void MessageLogger_Messages(object sender, EventMessage e)
private void MessageLoggerMessages(object sender, EventMessage e)
{
Console.WriteLine($"Log Level [{ e.Level }] Log Message [{ e.Message }] ");
}
Expand Down Expand Up @@ -205,7 +205,7 @@ public void DetermineTrackNumber(string filename)
}

[Fact]
public void ReadTotalTrackNumbersFromCue_Should_Be_Five()
public void ReadTotalTrackNumbersFromCueShouldBeFive()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\cues1";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -224,7 +224,7 @@ public void ReadTotalTrackNumbersFromCue_Should_Be_Five()
}

[Fact]
public void ReadTotalTrackNumbersFromCue_Should_Be_Eight()
public void ReadTotalTrackNumbersFromCueShouldBeEight()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\cues2";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -243,7 +243,7 @@ public void ReadTotalTrackNumbersFromCue_Should_Be_Eight()
}

[Fact]
public void ReadTotalTrackNumbersFromCue_Should_Be_Six()
public void ReadTotalTrackNumbersFromCueShouldBeSix()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\cues3";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -262,7 +262,7 @@ public void ReadTotalTrackNumbersFromCue_Should_Be_Six()
}

[Fact]
public void ReadTotalTrackNumbersFromCue_Should_Be_Nine()
public void ReadTotalTrackNumbersFromCueShouldBeNine()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\cues4";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -281,7 +281,7 @@ public void ReadTotalTrackNumbersFromCue_Should_Be_Nine()
}

[Fact]
public void ReadTotalTrackNumbersFromM3u_Should_Be_Eleven()
public void ReadTotalTrackNumbersFromM3uShouldBeEleven()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\m3u1";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -300,7 +300,7 @@ public void ReadTotalTrackNumbersFromM3u_Should_Be_Eleven()
}

[Fact]
public void ReadTotalTrackNumbersFromM3u_Should_Be_Four()
public void ReadTotalTrackNumbersFromM3uShouldBeFour()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\m3u2";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -319,7 +319,7 @@ public void ReadTotalTrackNumbersFromM3u_Should_Be_Four()
}

[Fact]
public void ReadTotalTrackNumbersFromM3u_Should_Be_Eight()
public void ReadTotalTrackNumbersFromM3uShouldBeEight()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\m3u3";
var directory = new DirectoryInfo(cuesDir);
Expand All @@ -338,7 +338,7 @@ public void ReadTotalTrackNumbersFromM3u_Should_Be_Eight()
}

[Fact]
public void ReadTotalTrackNumbersFromM3u_Should_Be_Fourteen()
public void ReadTotalTrackNumbersFromM3uShouldBeFourteen()
{
var cuesDir = @"C:\roadie_dev_root\test_cue_and_playlists\m3u4";
var directory = new DirectoryInfo(cuesDir);
Expand Down Expand Up @@ -545,7 +545,7 @@ public void ReadID3TagsFromFileWithAlbumNoTrackSet()
}

[Fact]
public void Read_File_Test_Is_valid()
public void ReadFileTestIsvalid()
{
var file = new FileInfo(@"M:\unknown\2eec19bd-3575-4b7f-84dd-db2a0ec3e2f3~[2009] Dolly - Disc 1 Of 4~06 Nobody But You (Previously Unissued).mp3");
if (file.Exists)
Expand All @@ -572,7 +572,7 @@ public void Read_File_Test_Is_valid()
}

[Fact]
public void Read_File_Test_Is_valid2()
public void ReadFileTestIsvalid2()
{
var file = new FileInfo(@"M:\library_old\Perverse\[2014] Champion Dub\01 Champion Dub (Original Mix).mp3");
if (file.Exists)
Expand All @@ -599,7 +599,7 @@ public void Read_File_Test_Is_valid2()
}

[Fact]
public void Read_File_Test_Is_valid3()
public void ReadFileTestIsvalid3()
{
var file = new FileInfo(@"C:\roadie_dev_root\inbound\Dreadful Fate - Vengeance (2018)\01-dreadful_fate-vengeance.mp3");
if (file.Exists)
Expand Down Expand Up @@ -685,7 +685,7 @@ public void ReadID3TagsFromFileWithArtistAndTrackArtist()
}

[Fact]
public void Write_Tags()
public void WriteTags()
{
var file = new FileInfo(@"C:\roadie_dev_root\inbound\temp\01. Re1nstall 0verture.mp3");
if (file.Exists)
Expand Down
2 changes: 1 addition & 1 deletion Roadie.Api.Library.Tests/ImageHasherTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace Roadie.Library.Tests
public class ImageHasherTests
{
[Fact]
public void Generate_Image_Hash()
public void GenerateImageHash()
{
var imageFilename = @"C:\temp\image_tests\1.jpg";
var secondImagFilename = @"C:\temp\image_tests\2.jpg";
Expand Down
Loading

0 comments on commit f385c8f

Please sign in to comment.