mirror of
https://github.com/Tyrrrz/DiscordChatExporter.git
synced 2026-02-14 07:43:31 -07:00
38 lines
932 B
C#
38 lines
932 B
C#
using System.Threading.Tasks;
|
|
using DiscordChatExporter.Cli.Tests.Fixtures;
|
|
using DiscordChatExporter.Cli.Tests.TestData;
|
|
using FluentAssertions;
|
|
using Xunit;
|
|
|
|
namespace DiscordChatExporter.Cli.Tests.Specs;
|
|
|
|
[Collection(nameof(ExportWrapperCollection))]
|
|
public class CsvContentSpecs
|
|
{
|
|
private readonly ExportWrapperFixture _exportWrapper;
|
|
|
|
public CsvContentSpecs(ExportWrapperFixture exportWrapper)
|
|
{
|
|
_exportWrapper = exportWrapper;
|
|
}
|
|
|
|
[Fact]
|
|
public async Task Messages_are_exported_correctly()
|
|
{
|
|
// Act
|
|
var document = await _exportWrapper.ExportAsCsvAsync(ChannelIds.DateRangeTestCases);
|
|
|
|
// Assert
|
|
document.Should().ContainAll(
|
|
"Tyrrrz#5447",
|
|
"Hello world",
|
|
"Goodbye world",
|
|
"Foo bar",
|
|
"Hurdle Durdle",
|
|
"One",
|
|
"Two",
|
|
"Three",
|
|
"Yeet"
|
|
);
|
|
}
|
|
} |