n8n/packages/nodes-base/nodes/DateTime/test/node/DateTime.test.ts
कारतोफ्फेलस्क्रिप्ट™ 52a2e25a25
fix(core): Replace all moment imports with moment-timezone (#8337)
2024-01-15 15:45:33 +01:00

16 lines
569 B
TypeScript

import moment from 'moment-timezone';
import { testWorkflows, getWorkflowFilenames } from '@test/nodes/Helpers';
const workflows = getWorkflowFilenames(__dirname);
// ! When making changes to the Workflow test files make sure to export env TZ=UTC as Github Actions runs in UTC timezone
if (new Date().getTimezoneOffset() === 0 || moment().utcOffset() === 0) {
describe('Test DateTime Node', () => testWorkflows(workflows));
} else {
describe('Test DateTime Node', () => {
it('Skipped because timezone is not UTC', () => {
expect(true).toBe(true);
});
});
}