mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
fix(editor): Fix empty objects in schema view in output panel (#14355)
This commit is contained in:
@@ -658,7 +658,22 @@ describe('VirtualSchema.vue', () => {
|
||||
expect(container).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('should do something', () => {
|
||||
expect(true).toBe(true);
|
||||
it('renders schema for empty objects and arrays', async () => {
|
||||
useWorkflowsStore().pinData({
|
||||
node: mockNode1,
|
||||
data: [{ json: { empty: {}, emptyArray: [], nested: [{ empty: {}, emptyArray: [] }] } }],
|
||||
});
|
||||
|
||||
const { container, getAllByTestId } = renderComponent({
|
||||
props: {
|
||||
nodes: [{ name: mockNode1.name, indicies: [], depth: 1 }],
|
||||
},
|
||||
});
|
||||
|
||||
await waitFor(() => {
|
||||
const headers = getAllByTestId('run-data-schema-header');
|
||||
expect(headers.length).toBe(2);
|
||||
});
|
||||
expect(container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user