Skip to content
This repository was archived by the owner on Mar 1, 2024. It is now read-only.
This repository was archived by the owner on Mar 1, 2024. It is now read-only.

inputComponents not rendering for nested properties #15

Description

@bananafunctor

As seen on bananafunctor@487ca3d specifically the test for nested inputComponents, they will fail to render right now.

Relevant code below

it('should render nested inputComponent', () => {
      const TestComponent = React.createClass({
          render() {
            return <p className="test">Hello, world!</p>;  
          }
      });

      const handlers = {
          testComponent : TestComponent
      };

      const nestedSchema = {
          "properties": {
              "Test": {
                  "x-hints": {
                      "form": {
                          "inputComponent": "testComponent"
                      }
                  }
              }
          }
      };
      const renderedForm = TestUtils.renderIntoDocument(<Form schema={nestedSchema}
                                                              handlers={handlers}/>);

      const paragraph = TestUtils.findRenderedDOMComponentWithClass(renderedForm, "test");

      expect(TestUtils.isCompositeComponentWithType(paragraph, TestComponent));
  })

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions