fal-js/libs/client/src/config.spec.ts
Daniel Rochetti f075fd914f
feat: support single fal_key env var (#10)
* feat: support single fal_key env var

* fix: default config and tests
2023-09-24 14:21:18 -07:00

15 lines
446 B
TypeScript

import { config, getConfig } from './config';
describe('The config test suite', () => {
it('should set the config variables accordingly', () => {
const newConfig = {
host: 'some-other-host',
credentials: 'key-id:key-secret',
};
config(newConfig);
const currentConfig = getConfig();
expect(currentConfig.host).toBe(newConfig.host);
expect(currentConfig.credentials).toEqual(newConfig.credentials);
});
});