@Test(expected = RuntimeException.class)
public void testLoad_throwsOnOptionalWithoutName() {

  String ingredients =
      String.join(
          "\n",
          "domain: 'test'",
          "ingredients:",
          "  - name: 'fooIngredient'",
          "    optionals:",
          "      - type: 'string'");

  loader.load(toStream(ingredients));
}