fix: match Kinglet aircraft exactly
This commit is contained in:
@@ -5,7 +5,7 @@ import { fileURLToPath } from "node:url";
|
||||
|
||||
import { migrateConfigurationRecord, migrateGiftGrantRecord, migratePlayerProfileRecord, migratePlayerRecord, migrateStatePatchRecord, migrateTrajectoryHistoryRecord, migrateTrajectoryRecord, migrationStatus } from "../examples/scum-server-plugin/features/migration.js";
|
||||
import { createGiftDelivery, deleteGiftDefinition, loadSCUMSurface, parseGiftCommands, parseGiftItems, queueGiftDelivery, resetGiftClaim, resetPendingGift, resolveMapBounds, saveEventProduce, saveGiftDefinition, saveMapSettings, scumCollections, startEvent, type RecordMap, type SCUMSurfaceData, type SCUMWorkspaceActions } from "../examples/scum-server-plugin/features/page-data.js";
|
||||
import { advanceMapPlayback, bundledVehicleImageUrl, collectMapPoints, mapPointStyle, playbackStartView, playbackFollowView } from "../examples/scum-server-plugin/features/page.js";
|
||||
import { advanceMapPlayback, bundledVehicleImageUrl, collectMapPoints, mapPointStyle, mapVehicleCategory, playbackStartView, playbackFollowView } from "../examples/scum-server-plugin/features/page.js";
|
||||
import type { MapTrack, MapTrackPoint } from "../examples/scum-server-plugin/features/contracts.js";
|
||||
import { renderPluginPage } from "../examples/scum-server-plugin/page-bundle/index.js";
|
||||
import { configurationCatalog, validateConfigPatch, validateStatePatch, validateVehicleSpawn, vehicleSpawnCatalog } from "../examples/scum-server-plugin/features/schemas.js";
|
||||
@@ -346,6 +346,14 @@ describe("SCUM plugin feature module", () => {
|
||||
expect(view.texts).toContain("Mira · 4 点");
|
||||
});
|
||||
|
||||
it("recognizes only the three Kinglet aircraft names in the flight filter", () => {
|
||||
expect(mapVehicleCategory({ className: "Kinglet_Duster_ES" })).toBe("air");
|
||||
expect(mapVehicleCategory({ className: "BPC_Kinglet_Mariner_C" })).toBe("air");
|
||||
expect(mapVehicleCategory({ label: "Kinglet Scout" })).toBe("air");
|
||||
expect(mapVehicleCategory({ className: "BPC_Laika_C" })).not.toBe("air");
|
||||
expect(mapVehicleCategory({ className: "Scout_ES" })).not.toBe("air");
|
||||
});
|
||||
|
||||
it("keeps the extracted icon catalog closed until an editor asks for it", () => {
|
||||
const gifts = renderAndCollect({ pageKey: "gifts", pageTitle: "礼包管理" });
|
||||
expect(gifts.texts).not.toContain("从 SCUM 目录选择礼包物品");
|
||||
|
||||
Reference in New Issue
Block a user