Skip to content

Commit

Permalink
feat: update no index
Browse files Browse the repository at this point in the history
Signed-off-by: David Dal Busco <[email protected]>
  • Loading branch information
peterpeterparker committed Nov 16, 2024
1 parent c9a8103 commit 17a30c9
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions src/tests/satellite.upgrade.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -557,4 +557,39 @@ describe('Satellite upgrade', () => {
});
});
});

describe('v0.0.20 -> v0.0.21', () => {
beforeEach(async () => {
pic = await PocketIc.create(inject('PIC_URL'));

const destination = await downloadSatellite('0.0.20');

const { actor: c, canisterId: cId } = await pic.setupCanister<SatelliteActor_0_0_16>({
idlFactory: idlFactorSatellite_0_0_16,
wasm: destination,
arg: controllersInitArgs(controller),
sender: controller.getPrincipal()
});

actor = c;
canisterId = cId;
actor.setIdentity(controller);
});

it('should not populate an index HTML file', async () => {
await upgrade();

const { http_request } = actor;

const { status_code } = await http_request({
body: [],
certificate_version: toNullable(),
headers: [],
method: 'GET',
url: '/'
});

expect(status_code).toBe(404);
});
});
});

0 comments on commit 17a30c9

Please sign in to comment.