UNPKG

xero-hero

Version:

Heroic utilities to simplify and enable your progress with the [xero-node](https://www.npmjs.com/package/xero-node) SDK.

39 lines (32 loc) 1.03 kB
// src/common/instance/operations.ts import { isObject } from "deep-cuts"; // src/accounting/attachments/requests.ts import { bufferToStream } from "tranquil-stream"; // src/accounting/contacts/links.ts import qs from "qs"; // src/accounting/invoices/lineItems.ts import { isNil } from "deep-cuts"; // src/accounting/journals/links.ts import qs2 from "qs"; // src/projects/generators.ts var generateProjectAmountUSD = (value) => { const amount = {}; amount.currency = "USD"; amount.value = value; return amount; }; // src/projects/timeEntries.ts import { roundToNearestFraction } from "deep-cuts"; // src/projects/__tests__/generators.test.ts describe("projects/generators", () => { describe("generateAmount()", () => { it("should return an Amount object with the given value as the USD Currency", () => { const amount = generateProjectAmountUSD(1e3); expect(amount).toEqual({ currency: "USD", value: 1e3 }); }); }); }); //# sourceMappingURL=generators.test.mjs.map