Skip to content

[Bug] hideRootObjectTitle test fails - root title returns empty string #1624

@Sbragul26

Description

@Sbragul26

Current Behavior

The hideRootObjectTitle.test.tsx test is failing because the title value is returned as an empty string ("") instead of "Import Design".

View failing test output
FAIL  src/__testing__/hideRootObjectTitle.test.tsx
  ● hideRootObjectTitle — RJSF root title/description derivation › renders the canonical root title by default (the duplicative heading)

    expect(received).toBe(expected) // Object.is equality

    Expected: "Import Design"
    Received: ""

      107 |   it('renders the canonical root title by default (the duplicative heading)', () => {
      108 |     const recorded = recordRootRender(importDesignUiSchema);
    > 109 |     expect(recorded.title).toBe('Import Design');
          |                            ^
      110 |   });

Expected Behavior

The test should pass and return the expected title value "Import Design".


Contributor Guides and Resources

Metadata

Metadata

Assignees

Labels

kind/bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions