You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// eslint-disable-next-line sonarjs/constructor-for-side-effects -- constructed only to validate the extracted inline script parses (throws SyntaxError otherwise); the instance itself is unused on purpose.
725
733
newvm.Script(script);
726
734
assert.ok(
@@ -743,6 +751,14 @@ function testAssetBrowserForwardsModelTextures() {
'code and object-data asset pickers should share the relevance scorer'
757
+
);
758
+
assert.ok(
759
+
!script.includes('text.indexOf(q[i], pos)'),
760
+
'asset search must not regress to scattered-letter subsequence matching'
761
+
);
746
762
}
747
763
748
764
functiontestThumbnailLifecycleGuards(){
@@ -778,6 +794,7 @@ function testThumbnailLifecycleGuards() {
778
794
assert.ok(objmod.includes('fetch(initial.thumbnailWorkerUri'),'the worker bundle must be fetched before creating its Blob URL');
779
795
assert.ok(!objmod.includes('new Worker(initial.thumbnailWorkerUri)'),'VS Code resource URLs cannot be passed directly to the Worker constructor');
780
796
assert.ok(assetBrowser.includes('modelThumbEnsureInit()'),'opening or selecting the model asset browser should prewarm the thumbnail worker');
797
+
assert.ok(assetBrowser.includes("import { assetSearchScore } from '../../features/preview/fuzzy'"),'objmod asset search should use the shared relevance scorer');
assert.ok(!ensureInit.includes('mpvViewer()'),'worker startup failure must not fall back to rendering on the objmod UI thread');
783
800
assert.ok(webpack.includes("mdxThumbnailWorker: './src/webview/mdxThumbnailWorker.ts'"),'the isolated thumbnail worker must be bundled');
@@ -921,6 +938,9 @@ function testObjModTooltipFontWiring() {
921
938
assert.ok(!host.includes("Buffer.from(bytes).toString('base64')"),'project fonts should not be embedded as large data URLs');
922
939
assert.ok(host.includes(".tt-collapsed-box,\n.tt-preview {"),'the custom font should be assigned only to tooltip boxes');
923
940
assert.ok(!host.includes('.tt-collapsed-box *'),'the custom font should not use descendant-wide override selectors');
941
+
assert.ok(host.includes('td.value { font-family: var(--font); }'),'ordinary field values should use the VS Code UI font');
942
+
assert.ok(host.includes('.tt-empty { color: var(--muted); font-style: normal; }'),'ordinary empty values should not be italicized');
943
+
assert.ok(host.includes('.tt-collapsed-box .tt-empty,'),'only framed WC3 text may retain the italic empty placeholder');
924
944
assert.ok(packageJson.includes('wurst.objModTooltipFont'),'the tooltip font setting should be contributed by the extension');
925
945
assert.equal(packageData.contributes.configuration.properties['wurst.objModTooltipFont'].default,'','the tooltip font setting must default to disabled');
926
946
}
@@ -944,10 +964,41 @@ function testObjModTooltipPreviewHeaders() {
assert.ok(fieldDisplay.includes("replace(/^(?:unit|building)\\s*\\/\\s*/i, '')"),'unit and building tooltip markers should be hidden in previews');
967
+
assert.ok(fieldDisplay.includes("label === 'name' || /\\bnames?$/"),'player-facing name fields should use the framed WC3 text editor');
947
968
assert.ok(detailsPanel.includes('renderWc3Colors(original)'),'tooltip editing should restore the unmodified raw value');
948
969
assert.ok(detailsPanel.includes('renderWc3Colors(tooltipPreviewText(value, isTooltipTemplateField(mod)))'),'tooltip collapse should restore the cleaned preview only for tooltip fields');
assert.ok(host.includes('id="density-toggle" class="density-toggle" role="switch"'),'density must render as an obvious switch control');
977
+
assert.ok(host.includes('aria-label="Spacious density"'),'density switch should have an unambiguous accessible name');
978
+
assert.ok(host.includes('class="density-track"'),'density switch should expose an animated visual track');
979
+
assert.ok(host.includes('body.density-cozy .density-thumb { transform: translateX(14px)'),'density switch thumb should animate between states');
980
+
assert.ok(host.includes('@media (prefers-reduced-motion: reduce)'),'density animation should respect reduced-motion preferences');
981
+
assert.ok(webview.includes("setAttribute('aria-checked', String(cozy))"),'density switch must expose its current state accessibly');
982
+
assert.ok(host.includes('font-size: 11px;\n font-weight: 500;\n color: var(--muted);'),'nested tree headings should share one typography baseline');
983
+
assert.ok(!host.includes('.race-heading {\n padding: var(--tree-heading-py) var(--ind-group) var(--tree-heading-py) var(--ind-race);\n color: var(--fg);\n font-size: 12px;'),'race headings should not introduce a third font treatment');
0 commit comments