RequiresTm1WebFactAttribute
using Skipcheck.Tm1.Testcontainers.Xunit;Runs a test class or method against real TM1 Web and TM1 servers, and skips it when either isn't available.
It includes RequiresTm1FactAttribute, so tests also skip without Docker or a
Tm1Source, and can still take a Tm1ServerContainer parameter. Declare a
Tm1WebContainer parameter to get the shared TM1 Web, which lists and logs on to the shared TM1 server:
public sealed class WebsheetTests(Tm1WebFixture web) : IClassFixture<Tm1WebFixture>
{
[RequiresTm1WebFact]
public void OpensAWebsheet()
{
// http://localhost:54321/tm1web/, which lists the shared TM1 server
Assert.EndsWith("/tm1web/", web.Tm1Web.Url);
// ...
}
}
Members
NoSourceMessage static | Why a test is skipped without a source. |
RequiresTm1WebFactAttribute constructor | Skips unless there's TM1 and TM1 Web to test against. |
NoDockerMessage static | Why a test is skipped without Docker. |
Tm1SkipReason static | Why a TM1 test is skipped, or null to run it (a wrong source runs it, to fail). |
NoSourceMessage
staticconst string NoSourceMessageWhy a test is skipped without a source.
RequiresTm1WebFactAttribute
constructorRequiresTm1WebFactAttribute()Skips unless there's TM1 and TM1 Web to test against.
NoDockerMessage
staticconst string NoDockerMessageWhy a test is skipped without Docker.
Tm1SkipReason
staticstring? Tm1SkipReason()Why a TM1 test is skipped, or null to run it (a wrong source runs it, to fail).