@Test
    void assertParseWriteWorksWithoutDefinitions() throws IOException, URISyntaxException {
        TraceFile traceFile = parseTraceFileFromFile(getClass().getResource("trace-file.json").toURI());

        //set definitions to null before writing and parsing again
        traceFile = traceFile.toBuilder().definitions(null).build();

        MockManifest manifest = writeTraceFileTestHelper(traceFile, "trace-file-output.json");
        TraceFile traceFile2 = parseTraceFileFromManifest(manifest, "trace-file-output.json");

        assertThat(traceFile.getMetadata().getId(), equalTo("software.amazon.awssdk.services:snowball:2.10.79"));
        assertThat(traceFile.getShapes().get(ShapeId.from("com.amazonaws.snowball#Snowball")).get(0).getType(),
                equalTo("TYPE"));
        assertThat(traceFile.getSmithyTrace(), equalTo("1.0"));
    }
Then parse the trace file, specify the files URI for parsing
Parsing fills all required fields and checks that they're filled
smithy-codegen-core/src/test/java/software/amazon/smithy/codegen/core/trace/TraceFileTest.java