Skip to content

Commit

Permalink
Removed Non-Working tests and improved TagCommand
Browse files Browse the repository at this point in the history
  • Loading branch information
sandreas committed Dec 14, 2024
1 parent fd780d3 commit 5b31f51
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/*
using System;
using System.IO;
using System.Net.Http;
Expand All @@ -16,6 +17,7 @@ public class AudibleIdTaggerTest
[Fact]
public async void TestUpdateTag()
{
var dataPath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location + "/../../../../data/");
var settings = new AudibleIdTaggerSettings()
{
Expand All @@ -27,17 +29,18 @@ public async void TestUpdateTag()
{
Id = "B0092PNN4O"
};
var track = new MetadataTrack();
var track = new MetadataTrackHolder();
var result = await tagger.UpdateAsync(track);
Assert.Equal("Der Name des Windes", track.Title);
// Assert.Equal(250, track.Chapters.Count);
/*
var x = new ChptFmtNativeMetadataFormat();
var mem = new MemoryStream();
await x.WriteAsync(track, mem);
File.WriteAllText("/home/mediacenter/projects/tone/tone/var/tmp/test.txt", mem.StreamToString());
Assert.Equal("", mem.StreamToString());
*/
}
}
}
*/
3 changes: 2 additions & 1 deletion tone/Commands/TagCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,10 @@ public override async Task<int> ExecuteAsync(CommandContext context, TagCommandS
return (ReturnCode.UserAbort, shouldShowDryRunMessage);
}


var track = new MetadataTrack(file)
{
BasePath = p.BaseDirectory?.FullName
BasePath = file.DirectoryName
};
var status = await _tagger.UpdateAsync(track);

Expand Down

0 comments on commit 5b31f51

Please sign in to comment.