mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 19:04:02 +00:00
Merge pull request #1461 from quanticsoul4772/upstream/sky-test-windows-path
fix(sky): read the Milky Way faces by file path in the paint-out test
This commit is contained in:
1 file changed
+2
-1
@@ -1,5 +1,6 @@
|
|||||||
import assert from 'node:assert/strict';
|
import assert from 'node:assert/strict';
|
||||||
import test from 'node:test';
|
import test from 'node:test';
|
||||||
|
import { fileURLToPath } from 'node:url';
|
||||||
import sharp from 'sharp';
|
import sharp from 'sharp';
|
||||||
import {
|
import {
|
||||||
CUBE_FACES,
|
CUBE_FACES,
|
||||||
@@ -24,7 +25,7 @@ test('painted-out planets leave no disc brighter than the sky around them', asyn
|
|||||||
}));
|
}));
|
||||||
for (const face of CUBE_FACES) {
|
for (const face of CUBE_FACES) {
|
||||||
const { data, info } = await sharp(
|
const { data, info } = await sharp(
|
||||||
new URL(`milkyway_${FACE_FILE_SUFFIX[face]}.webp`, SKY).pathname,
|
fileURLToPath(new URL(`milkyway_${FACE_FILE_SUFFIX[face]}.webp`, SKY)),
|
||||||
)
|
)
|
||||||
.raw()
|
.raw()
|
||||||
.toBuffer({ resolveWithObject: true });
|
.toBuffer({ resolveWithObject: true });
|
||||||
|
|||||||
Reference in new issue
Block a user