Skip to content

Commit

Permalink
trying to fix weird ci issue with fetching file by using readFileSync…
Browse files Browse the repository at this point in the history
… instead
  • Loading branch information
DanielJDufour committed Jun 8, 2024
1 parent f53c595 commit 4faff44
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/stats/stats.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -279,9 +279,8 @@ test("virtual resampling, contained", async ({ eq }) => {
});

test("virtual resampling, intersecting 4 pixels", async ({ eq }) => {
await new Promise(resolve => setTimeout(resolve, 5*1000)); // avoid failed fetching
const url = "http://localhost:3000/data/geotiff-test-data/nz_habitat_anticross_4326_1deg.tif";
const geojson = await fetch("http://localhost:3000/data/virtual-resampling/virtual-resampling-intersect.geojson").then(res => res.json());
const geojson = JSON.parse(readFileSync("./data/virtual-resampling/virtual-resampling-intersect.geojson", "utf-8"));
const result = await stats(url, geojson, null, null, { include_meta: false, rescale: true, vrm: [10, 10] });
eq(result, [
{
Expand Down

0 comments on commit 4faff44

Please sign in to comment.