1
0
mirror of https://github.com/bitwarden/server.git synced 2024-11-21 12:05:42 +01:00

Ignore expired licenses in tests to check overall validity (#3495)

This commit is contained in:
Addison Beck 2023-11-30 14:49:49 -06:00 committed by GitHub
parent a2eadfd9be
commit 88405fd0ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -39,6 +39,10 @@ public class OrganizationLicenseTests
public void OrganizationLicense_LoadedFromDisk_VerifyData_Passes(int licenseVersion)
{
var license = OrganizationLicenseFileFixtures.GetVersion(licenseVersion);
// These licenses will naturally expire over time, but we still want them to be able to test
license.Expires = DateTime.MaxValue;
var organization = OrganizationLicenseFileFixtures.OrganizationFactory();
var globalSettings = Substitute.For<IGlobalSettings>();
globalSettings.Installation.Returns(new GlobalSettings.InstallationSettings