DiscordChatExporter/DiscordChatExporter.Cli.Tests
2021-07-24 18:17:07 +03:00
..
Fixtures Fix isolation in tests 2021-07-19 21:07:36 +03:00
Infra Add test instructions 2021-07-24 18:15:16 +03:00
TestData More tests 2021-07-19 20:35:27 +03:00
Utils Improve tests 2021-07-19 20:19:32 +03:00
DiscordChatExporter.Cli.Tests.csproj Fix coverage collection in tests 2021-07-19 22:28:30 +03:00
EmbedSpecs.cs [HTML] Special case Spotify embeds 2021-07-23 00:54:00 +03:00
MentionSpecs.cs Test improvements 2021-07-19 23:13:52 +03:00
Readme.md Update tests readme 2021-07-24 18:17:07 +03:00
ReplySpecs.cs Test improvements 2021-07-19 23:13:52 +03:00
xunit.runner.json Basic automated tests through the CLI 2021-07-19 20:09:35 +03:00

DiscordChatExporter Tests

This test suite runs against a real Discord server, specifically created to exercise different behaviors required by the test scenarios. In order to run these tests locally, you need to join the test server and configure your authentication token.

  1. Join the server: https://discord.gg/eRV8Vap5bm
  2. Locate your Discord authentication token
  3. Specify your token using a file or an environment variable:
    • Using a file: put your token in a new DiscordToken.secret file created in this directory
    • Using an environment variable: set DISCORD_TOKEN variable to your token
  4. Run the tests: dotnet test

If you're submitting a pull request, you don't have to run the tests locally -- they are executed automatically by CI. Running them locally can still sometimes be useful for debugging purposes though.

If you want to have a new test case or a scenario added, please let me know in your pull request. Currently, it's not possible to add them by yourself.