auto-git:
[change] tests/domain/scene-document-validation.test.ts [change] tests/domain/world-settings.test.ts [change] tests/serialization/project-document-json.test.ts
This commit is contained in:
@@ -1172,6 +1172,7 @@ describe("validateSceneDocument", () => {
|
|||||||
};
|
};
|
||||||
document.world.shaderSky.dayTopColorHex = "bad-color" as `#${string}`;
|
document.world.shaderSky.dayTopColorHex = "bad-color" as `#${string}`;
|
||||||
document.world.shaderSky.horizonHeight = 0.75;
|
document.world.shaderSky.horizonHeight = 0.75;
|
||||||
|
document.world.shaderSky.stars.horizonFadeOffset = 0.75;
|
||||||
document.world.shaderSky.celestial.sunDiscSizeDegrees = 0;
|
document.world.shaderSky.celestial.sunDiscSizeDegrees = 0;
|
||||||
document.world.shaderSky.clouds.coverage = 2;
|
document.world.shaderSky.clouds.coverage = 2;
|
||||||
document.world.timeOfDay.dawn.background = {
|
document.world.timeOfDay.dawn.background = {
|
||||||
@@ -1190,6 +1191,10 @@ describe("validateSceneDocument", () => {
|
|||||||
code: "invalid-world-shader-sky-horizon-height",
|
code: "invalid-world-shader-sky-horizon-height",
|
||||||
path: "world.shaderSky.horizonHeight"
|
path: "world.shaderSky.horizonHeight"
|
||||||
}),
|
}),
|
||||||
|
expect.objectContaining({
|
||||||
|
code: "invalid-world-shader-sky-star-horizon-fade-offset",
|
||||||
|
path: "world.shaderSky.stars.horizonFadeOffset"
|
||||||
|
}),
|
||||||
expect.objectContaining({
|
expect.objectContaining({
|
||||||
code: "invalid-world-shader-sky-sun-disc-size",
|
code: "invalid-world-shader-sky-sun-disc-size",
|
||||||
path: "world.shaderSky.celestial.sunDiscSizeDegrees"
|
path: "world.shaderSky.celestial.sunDiscSizeDegrees"
|
||||||
|
|||||||
@@ -177,4 +177,13 @@ describe("world settings helpers", () => {
|
|||||||
|
|
||||||
expect(areWorldSettingsEqual(left, right)).toBe(false);
|
expect(areWorldSettingsEqual(left, right)).toBe(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("treats shader sky star horizon offset as part of authored world equality", () => {
|
||||||
|
const left = createDefaultWorldSettings();
|
||||||
|
const right = cloneWorldSettings(left);
|
||||||
|
|
||||||
|
right.shaderSky.stars.horizonFadeOffset = 0.08;
|
||||||
|
|
||||||
|
expect(areWorldSettingsEqual(left, right)).toBe(false);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -69,6 +69,7 @@ describe("project document JSON", () => {
|
|||||||
activeScene.world.shaderSky.dayBottomColorHex = "#d6efff";
|
activeScene.world.shaderSky.dayBottomColorHex = "#d6efff";
|
||||||
activeScene.world.shaderSky.horizonHeight = -0.06;
|
activeScene.world.shaderSky.horizonHeight = -0.06;
|
||||||
activeScene.world.shaderSky.stars.density = 0.72;
|
activeScene.world.shaderSky.stars.density = 0.72;
|
||||||
|
activeScene.world.shaderSky.stars.horizonFadeOffset = 0.09;
|
||||||
activeScene.world.shaderSky.clouds.coverage = 0.63;
|
activeScene.world.shaderSky.clouds.coverage = 0.63;
|
||||||
activeScene.world.shaderSky.clouds.tintHex = "#ece7df";
|
activeScene.world.shaderSky.clouds.tintHex = "#ece7df";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user