Allow BYOND downloads to be configurable

This commit is contained in:
Jordan Dominion
2025-06-23 21:35:28 -04:00
parent c99208b823
commit fb2b15134f
6 changed files with 137 additions and 27 deletions
@@ -0,0 +1,23 @@
using System;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace Tgstation.Server.Host.Components.Engine.Tests
{
[TestClass]
public sealed class TestByondInstallerBase
{
[TestMethod]
public void TestUrlTemplateFormatting()
{
const string OSMarker = "TempleOS";
Assert.AreEqual(
new Uri("https://example.com/$515.1111_Hello Worl$d.zip"),
ByondInstallerBase.GetDownloadZipUrl(
new Version(515, 1111),
"https://example.com/$$${Major}.${Minor}_${TempleOS:Hello Worl$$d}.zip${Linux:Not this}${Or This}",
OSMarker));
}
}
}