use of com.navercorp.pinpoint.profiler.metadata.StringMetaDataService in project pinpoint by naver.
the class WrappedSpanEventRecorderTest method testRecordAPIId.
@Test
public void testRecordAPIId() throws Exception {
Span span = new Span();
SpanEvent spanEvent = new SpanEvent(span);
StringMetaDataService stringMetaDataService = Mockito.mock(StringMetaDataService.class);
SqlMetaDataService sqlMetaDataService = Mockito.mock(SqlMetaDataService.class);
WrappedSpanEventRecorder recorder = new WrappedSpanEventRecorder(stringMetaDataService, sqlMetaDataService);
recorder.setWrapped(spanEvent);
final int API_ID = 1000;
recorder.recordApiId(API_ID);
Assert.assertEquals("API ID", spanEvent.getApiId(), API_ID);
}
Aggregations