Class CutsceneCreatorTests
EditMode tests for CutsceneCreator's Addressables registration of the created
UnityCutscenePlayerSettings asset. Every test targets a fixture cutscene under a private temp
folder — the real project-wide single settings asset (used by the production wizard) is never touched,
so these tests stay hermetic regardless of what the project already has configured. Mirrors
Serenity.GameSave.Tests.Editor.Builder.GameSaveCreatorTests. The one exception is
Create_SecondCutsceneAfterAFirstOne_LandsAsASibling(): Serenity.Global.Infrastructure.Editor.SerenityDefaultAssetFolder.ResolveFor``1(System.String)
scans the whole project with no folder scope, so that test asserts a precondition (exactly one
non-package UnityCutscenePlayerSettings) before trusting its result, rather than being scoped
to the temp folder itself.
Inherited Members
Namespace: Serenity.CutscenePlayer.Tests.Editor.Builder
Assembly: Serenity.CutscenePlayer.Tests.Editor.dll
Syntax
public class CutsceneCreatorTests
Constructors
CutsceneCreatorTests()
Declaration
public CutsceneCreatorTests()
Methods
Create_MediaFolderMissing_CreatesTheFolderAndTheDefinition()
Declaration
public void Create_MediaFolderMissing_CreatesTheFolderAndTheDefinition()
Create_NoExistingPlayerSettings_CreatesOneAndTagsItWithTheCutsceneLabel()
Declaration
public void Create_NoExistingPlayerSettings_CreatesOneAndTagsItWithTheCutsceneLabel()
Create_RegisterAsAddressablesFalse_LeavesTheAddressablesSettingsUntouched()
Declaration
public void Create_RegisterAsAddressablesFalse_LeavesTheAddressablesSettingsUntouched()
Create_SecondCutsceneAfterAFirstOne_LandsAsASibling()
Regression test for the Cutscene Wizard nesting bug (audit §3.2/§3.7): a second cutscene's Media
Folder must not seed from the first cutscene's own leaf ("{root}/{firstId}"). Reproduces
CreateCutsceneWindow.OnEnable's reseed exactly — the same Serenity.Global.Infrastructure.Editor.SerenityDefaultAssetFolder
majority scan, but by UnityCutscenePlayerSettings (the project's single, never-nested
registry asset) rather than by UnityCutsceneDefinition, which nests one level deeper per
cutscene and would resolve back onto the first cutscene's own folder — asserted directly below as
the negative control the old (buggy) type argument would have produced.
Serenity.Global.Infrastructure.Editor.SerenityDefaultAssetFolder.ResolveFor``1(System.String) scans the whole project with no folder
scope, so both resolutions below are only trustworthy while the fixture just created is the ONLY
non-package instance of its type; the precondition asserts stay ahead of that instead of letting a
leaked fixture elsewhere flip the majority silently.
Declaration
public void Create_SecondCutsceneAfterAFirstOne_LandsAsASibling()
OneTimeTearDown()
Declaration
public static void OneTimeTearDown()
SetUp()
Declaration
public void SetUp()
TearDown()
Declaration
public void TearDown()
Validate_MediaFolderMissing_IsAccepted()
Declaration
public void Validate_MediaFolderMissing_IsAccepted()