@Test
  public void testDecode_failsWhenMissingFields() {
    assertNull(
        "Expected null tag to cause decoding to fail",
        coder.decode(
            coder.encode(setValidBuilderDefaults(builder).setTag(null).build(), new Bundle())));

    assertNull(
        "Expected null service to cause decoding to fail",
        coder.decode(
            coder.encode(setValidBuilderDefaults(builder).setService(null).build(), new Bundle())));
  }
Tests for the {@link JobCoder} class.
jobdispatcher/src/test/java/com/firebase/jobdispatcher/JobCoderTest.java