I have a class like the following:
export class TestClient {
@InjectValue("VALUE_A")
private valueA: string;
public constructor(accessToken: string) {
const object = {
host: this.valueA
};
}
}
How can I mock, inject, pass a value to valueA
from the Jest test file?
it("Should instantiate the client", () => {
const client = new TestClient("");
expect(client).toBeInstanceOf(TestClient);
});
2