@Test public void testConstructor() { assertEquals(REASON, ERROR.getReason()); assertEquals(LOCATION, ERROR.getLocation()); assertEquals(DEBUG_INFO, ERROR.getDebugInfo()); assertEquals(MESSAGE, ERROR.getMessage()); assertEquals(REASON, ERROR_INCOMPLETE.getReason()); assertEquals(LOCATION, ERROR_INCOMPLETE.getLocation()); assertEquals(null, ERROR_INCOMPLETE.getDebugInfo()); assertEquals(MESSAGE, ERROR_INCOMPLETE.getMessage()); }
private void compareBigQueryError(BigQueryError expected, BigQueryError value) { assertEquals(expected, value); assertEquals(expected.hashCode(), value.hashCode()); assertEquals(expected.toString(), value.toString()); assertEquals(expected.getReason(), value.getReason()); assertEquals(expected.getLocation(), value.getLocation()); assertEquals(expected.getDebugInfo(), value.getDebugInfo()); assertEquals(expected.getMessage(), value.getMessage()); } }
attributes.put(BigQueryAttributes.JOB_ERROR_MSG_ATTR, job.getStatus().getError().getMessage()); attributes.put(BigQueryAttributes.JOB_ERROR_REASON_ATTR, job.getStatus().getError().getReason()); attributes.put(BigQueryAttributes.JOB_ERROR_LOCATION_ATTR, job.getStatus().getError().getLocation()); } else {