// Path: src/test/java/com/squareup/protoparser/TestUtils.java
// @SafeVarargs
// static <T> List<T> list(T... values) {
//   return Arrays.asList(values);
// }
// 
// Path: src/test/java/com/squareup/protoparser/TestUtils.java
// static Map<String, Object> map(Object... keysAndValues) {
//   Map<String, Object> result = new LinkedHashMap<>();
//   for (int i = 0; i < keysAndValues.length; i += 2) {
//     result.put((String) keysAndValues[i], keysAndValues[i + 1]);
//   }
//   return result;
// }


import java.util.List;
import java.util.Map;
import org.junit.Test;
import static com.squareup.protoparser.OptionElement.Kind.BOOLEAN;
import static com.squareup.protoparser.OptionElement.Kind.LIST;
import static com.squareup.protoparser.OptionElement.Kind.MAP;
import static com.squareup.protoparser.OptionElement.Kind.OPTION;
import static com.squareup.protoparser.OptionElement.Kind.STRING;
import static com.squareup.protoparser.TestUtils.list;
import static com.squareup.protoparser.TestUtils.map;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.data.MapEntry.entry;
import static org.junit.Assert.fail;
    }
  }

  @Test public void simpleToSchema() {
    OptionElement option = OptionElement.create("foo", STRING, "bar");
    String expected = "foo = \"bar\"";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void nestedToSchema() {
    OptionElement option =
        OptionElement.create("foo.boo", OPTION, OptionElement.create("bar", STRING, "baz"), true);
    String expected = "(foo.boo).bar = \"baz\"";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void listToSchema() {
    OptionElement option = OptionElement.create("foo", LIST,
        list(OptionElement.create("ping", STRING, "pong", true),
            OptionElement.create("kit", STRING, "kat")), true);
    String expected = ""
        + "(foo) = [\n"
        + "  (ping) = \"pong\",\n"
        + "  kit = \"kat\"\n"
        + "]";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void mapToSchema() {
    OptionElement option =
// Path: src/test/java/com/squareup/protoparser/TestUtils.java
// @SafeVarargs
// static <T> List<T> list(T... values) {
//   return Arrays.asList(values);
// }
// 
// Path: src/test/java/com/squareup/protoparser/TestUtils.java
// static Map<String, Object> map(Object... keysAndValues) {
//   Map<String, Object> result = new LinkedHashMap<>();
//   for (int i = 0; i < keysAndValues.length; i += 2) {
//     result.put((String) keysAndValues[i], keysAndValues[i + 1]);
//   }
//   return result;
// }


// Path: src/test/java/com/squareup/protoparser/OptionElementTest.java
import java.util.List;
import java.util.Map;
import org.junit.Test;
import static com.squareup.protoparser.OptionElement.Kind.BOOLEAN;
import static com.squareup.protoparser.OptionElement.Kind.LIST;
import static com.squareup.protoparser.OptionElement.Kind.MAP;
import static com.squareup.protoparser.OptionElement.Kind.OPTION;
import static com.squareup.protoparser.OptionElement.Kind.STRING;
import static com.squareup.protoparser.TestUtils.list;
import static com.squareup.protoparser.TestUtils.map;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.data.MapEntry.entry;
import static org.junit.Assert.fail;

    }
  }

  @Test public void simpleToSchema() {
    OptionElement option = OptionElement.create("foo", STRING, "bar");
    String expected = "foo = \"bar\"";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void nestedToSchema() {
    OptionElement option =
        OptionElement.create("foo.boo", OPTION, OptionElement.create("bar", STRING, "baz"), true);
    String expected = "(foo.boo).bar = \"baz\"";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void listToSchema() {
    OptionElement option = OptionElement.create("foo", LIST,
        list(OptionElement.create("ping", STRING, "pong", true),
            OptionElement.create("kit", STRING, "kat")), true);
    String expected = ""
        + "(foo) = [\n"
        + "  (ping) = \"pong\",\n"
        + "  kit = \"kat\"\n"
        + "]";
    assertThat(option.toSchema()).isEqualTo(expected);
  }

  @Test public void mapToSchema() {
    OptionElement option =
        OptionElement.create("foo", MAP, map("ping", "pong", "kit", list("kat", "kot")));