package com.google.fhirengine.resource;

import org.hl7.fhir.r4.model.Resource;

import javax.inject.Inject;

import ca.uhn.fhir.parser.IParser;

import static org.junit.Assert.assertEquals;

public class TestingUtils {
  private final IParser iParser;

  @Inject
  public TestingUtils(IParser iParser) {
    this.iParser = iParser;
  }

  /** Asserts that the {@code expected} and the {@code actual} FHIR resources are equal. */
  public void assertResourceEquals(Resource expected, Resource actual) {
    assertEquals(iParser.encodeResourceToString(expected),
        iParser.encodeResourceToString(actual));
  }
}

@@ -185,16 +185,46 @@
 quals;%0A%0A
+/** Utilities for testing. */%0A
 public c

Add javadoc for TestingUtils class.