test_class.file: metrics-influxdb/src/test/java/com/izettle/metrics/influxdb/utils/TimeUtilsTest.java
test_class.identifier: TimeUtilsTest
test_case.body: @Test
      public void test() {
          assertThat("m".equals(TimeUtils.toTimePrecision(TimeUnit.MINUTES)));
          assertThat("h".equals(TimeUtils.toTimePrecision(TimeUnit.HOURS)));
          assertThat("s".equals(TimeUtils.toTimePrecision(TimeUnit.SECONDS)));
          assertThat("ms".equals(TimeUtils.toTimePrecision(TimeUnit.MILLISECONDS)));
          assertThat("u".equals(TimeUtils.toTimePrecision(TimeUnit.MICROSECONDS)));
          assertThat("n".equals(TimeUtils.toTimePrecision(TimeUnit.NANOSECONDS)));
      }
test_case.class_method_signature: TimeUtilsTest.test()
test_case.full_signature: @Test public void test()
test_case.identifier: test
test_case.invocations: assertThat equals toTimePrecision assertThat equals toTimePrecision assertThat equals toTimePrecision assertThat equals toTimePrecision assertThat equals toTimePrecision assertThat equals toTimePrecision
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void test()
focal_class.file: metrics-influxdb/src/main/java/com/izettle/metrics/influxdb/utils/TimeUtils.java
focal_class.identifier: TimeUtils
focal_class.class_method_signature: TimeUtils.toTimePrecision(final TimeUnit t)
focal_class.full_signature: public static String toTimePrecision(final TimeUnit t)
focal_class.identifier: toTimePrecision
focal_class.modifiers: public static
focal_class.parameters: (final TimeUnit t)
focal_class.return: String
focal_class.signature: String toTimePrecision(final TimeUnit t)
focal_method.body: public static String toTimePrecision(final TimeUnit t) {
          switch (t) {
              case HOURS:
                  return "h";
              case MINUTES:
                  return "m";
              case SECONDS:
                  return "s";
              case MILLISECONDS:
                  return "ms";
              case MICROSECONDS:
                  return "u";
              case NANOSECONDS:
                  return "n";
              default:
                  EnumSet<TimeUnit> allowedTimeunits = EnumSet.of(
                      TimeUnit.HOURS,
                      TimeUnit.MINUTES,
                      TimeUnit.SECONDS,
                      TimeUnit.MILLISECONDS,
                      TimeUnit.MICROSECONDS,
                      TimeUnit.NANOSECONDS);
                  throw new IllegalArgumentException("time precision must be one of:" + allowedTimeunits);
          }
      }
focal_method.class_method_signature: TimeUtils.toTimePrecision(final TimeUnit t)
focal_method.full_signature: public static String toTimePrecision(final TimeUnit t)
focal_method.identifier: toTimePrecision
focal_method.invocations: of
focal_method.modifiers: public static
focal_method.parameters: (final TimeUnit t)
focal_method.return: String
focal_method.signature: String toTimePrecision(final TimeUnit t)