101 featch available variables from previous steps (#8062)
- add outputSchema in workflow step settings - use outputSchemas to compute step available variables https://github.com/user-attachments/assets/6b851d8e-625c-49ff-b29c-074cd86cbfee
This commit is contained in:
@ -3,13 +3,18 @@ import { findAvailableTimeZoneOption } from '@/localization/utils/findAvailableT
|
||||
describe('findAvailableTimeZoneOption', () => {
|
||||
it('should find the matching available IANA time zone select option from a given IANA time zone', () => {
|
||||
const ianaTimeZone = 'Europe/Paris';
|
||||
const expectedOption = {
|
||||
label: '(GMT+02:00) Central European Summer Time - Paris',
|
||||
value: 'Europe/Paris',
|
||||
};
|
||||
const expectedValue = 'Europe/Paris';
|
||||
const expectedLabelWinter =
|
||||
'(GMT+01:00) Central European Standard Time - Paris';
|
||||
const expectedLabelSummer =
|
||||
'(GMT+02:00) Central European Summer Time - Paris';
|
||||
|
||||
const option = findAvailableTimeZoneOption(ianaTimeZone);
|
||||
|
||||
expect(option).toEqual(expectedOption);
|
||||
expect(option.value).toEqual(expectedValue);
|
||||
expect(
|
||||
expectedLabelWinter === option.label ||
|
||||
expectedLabelSummer === option.label,
|
||||
).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
||||
@ -3,11 +3,17 @@ import { formatTimeZoneLabel } from '@/localization/utils/formatTimeZoneLabel';
|
||||
describe('formatTimeZoneLabel', () => {
|
||||
it('should format the time zone label correctly when location is included in the label', () => {
|
||||
const ianaTimeZone = 'Europe/Paris';
|
||||
const expectedLabel = '(GMT+02:00) Central European Summer Time - Paris';
|
||||
const expectedLabelSummer =
|
||||
'(GMT+02:00) Central European Summer Time - Paris';
|
||||
const expectedLabelWinter =
|
||||
'(GMT+01:00) Central European Standard Time - Paris';
|
||||
|
||||
const formattedLabel = formatTimeZoneLabel(ianaTimeZone);
|
||||
|
||||
expect(formattedLabel).toEqual(expectedLabel);
|
||||
expect(
|
||||
expectedLabelSummer === formattedLabel ||
|
||||
expectedLabelWinter === formattedLabel,
|
||||
).toBeTruthy();
|
||||
});
|
||||
|
||||
it('should format the time zone label correctly when location is not included in the label', () => {
|
||||
|
||||
Reference in New Issue
Block a user