Skip to content

Commit

Permalink
Empty Asar initialisation test
Browse files Browse the repository at this point in the history
  • Loading branch information
lafkpages committed Oct 16, 2023
1 parent 082a977 commit bfd3583
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,18 @@ test("new Asar", () => {
expect(asar).toBeInstanceOf(Asar);
});

test("new Asar [empty]", () => {
const emptyAsar = new Asar();

expect(emptyAsar).toBeDefined();
expect(emptyAsar).toBeInstanceOf(Asar);

const files = emptyAsar.listFiles();

expect(files).toBeArray();
expect(files).toBeEmpty();
});

test("Asar.initialParseData.headerSize", async () => {
expect(asar.initialParseData?.headerSize).toBeNumber();
// Now we can "!" assert it
Expand Down

0 comments on commit bfd3583

Please sign in to comment.