@Test
  public void testWriteToBundle_unmeteredConstraintShouldTakePrecendence() {
    Bundle b =
        writer.writeToBundle(
            initializeDefaultBuilder()
                .setConstraints(Constraint.ON_ANY_NETWORK, Constraint.ON_UNMETERED_NETWORK)
                .build(),
            new Bundle());

    assertEquals(
        "expected ON_UNMETERED_NETWORK to take precendence over ON_ANY_NETWORK",
        GooglePlayJobWriter.LEGACY_NETWORK_UNMETERED,
        b.getInt("requiredNetwork"));
  }
Tests for the {@link GooglePlayJobWriter} class.
jobdispatcher/src/test/java/com/firebase/jobdispatcher/GooglePlayJobWriterTest.java