Files
Ole André Vadla RavnåsandHåvard Sørbø e2ffd0aa6c Auto-generate Node-API bindings from .gir
Which means API changes in frida-core are instantly reflected, with only
customizations needing tweaking, if applicable.

And, since we now target Node-API there will now only be one prebuilt
binary per OS/ABI.

Co-authored-by: Håvard Sørbø <[email protected]>
2025-05-08 10:05:20 +02:00

27 lines
742 B
TypeScript

import { expect } from "chai";
import frida from "frida";
import "mocha";
declare function gc(): void;
describe("Device", function () {
afterEach(gc);
it("should have some metadata", async () => {
const device = await frida.getLocalDevice();
expect(device.name).to.equal("Local System");
expect(device.type).to.equal("local");
});
it("should enumerate processes", async () => {
const device = await frida.getLocalDevice();
const processes = await device.enumerateProcesses();
expect(processes.length).to.be.above(0);
const process = processes[0];
expect(process.pid).to.be.at.least(0);
expect(process.name.length).to.be.greaterThan(0);
});
});