test_class.declarator: CI_ID=66L
test_class.modifier: private static final
test_class.original_string: private static final Long CI_ID=66L;
test_class.type: Long
test_class.var_name: CI_ID
test_class.declarator: BUCKET = "bucket-a"
test_class.modifier: private static final
test_class.original_string: private static final String BUCKET = "bucket-a";
test_class.type: String
test_class.var_name: BUCKET
test_class.declarator: CI_STATE = "state-pending"
test_class.modifier: private static final
test_class.original_string: private static final String CI_STATE = "state-pending";
test_class.type: String
test_class.var_name: CI_STATE
test_class.declarator: CI_MANIFEST_ID = 4321L
test_class.modifier: private static final
test_class.original_string: private static final Long CI_MANIFEST_ID = 4321L;
test_class.type: Long
test_class.var_name: CI_MANIFEST_ID
test_class.declarator: CI_SOURCE = "source-mocked"
test_class.modifier: private static final
test_class.original_string: private static final String CI_SOURCE = "source-mocked";
test_class.type: String
test_class.var_name: CI_SOURCE
test_class.declarator: CI_TYPE = "closed-state-a"
test_class.modifier: private static final
test_class.original_string: private static final String CI_TYPE = "closed-state-a";
test_class.type: String
test_class.var_name: CI_TYPE
test_class.declarator: CI_TIMESTAMP = 102222L
test_class.modifier: private static final
test_class.original_string: private static final Long CI_TIMESTAMP = 102222L;
test_class.type: Long
test_class.var_name: CI_TIMESTAMP
test_class.declarator: P_KEY = "swaps"
test_class.modifier: private static final
test_class.original_string: private static final String P_KEY = "swaps";
test_class.type: String
test_class.var_name: P_KEY
test_class.declarator: P_VAL = 66D
test_class.modifier: private static final
test_class.original_string: private static final Double P_VAL = 66D;
test_class.type: Double
test_class.var_name: P_VAL
test_class.file: sensor/src/test/java/com/oneops/sensor/util/EventConverterTest.java
test_class.identifier: EventConverterTest
test_case.body: @Test
  	/** again and similar but pass in a close event */
  	public void testEventClosed(){
  		
  		OpsCloseEvent opsCloseEvent = new OpsCloseEvent();
  		opsCloseEvent.setBucket(BUCKET);
  		opsCloseEvent.setCiId(CI_ID);
  		opsCloseEvent.setCiState(CI_STATE);
  		opsCloseEvent.setManifestId(CI_MANIFEST_ID);
  		opsCloseEvent.setSource(CI_SOURCE);
  		opsCloseEvent.setType(CI_TYPE);
  		opsCloseEvent.setTimestamp(CI_TIMESTAMP);
  		
  		PerfEventPayload metrics = new PerfEventPayload();
  		Map<String, Double> countMap = new HashMap<String, Double>(1);
  		countMap.put(P_KEY, P_VAL);
  		metrics.setCount(countMap);
  		opsCloseEvent.setMetrics(metrics);
  				
  		OpsBaseEvent convertedOut = EventConverter.convert(opsCloseEvent);
  		
  		assertEquals(convertedOut.getBucket(),BUCKET);
  		assertEquals(convertedOut.getCiState(),CI_STATE);
  		assertEquals(convertedOut.getSource(),CI_SOURCE);
  		assertEquals(convertedOut.getType(),CI_TYPE);
  		assertEquals(convertedOut.getMetrics(),metrics);
  		
  		assert(CI_TIMESTAMP.equals(convertedOut.getTimestamp()));
  		assert(CI_MANIFEST_ID.equals(convertedOut.getManifestId()));
  		assert(CI_ID.equals(convertedOut.getCiId() ));	
  	}
test_case.class_method_signature: EventConverterTest.testEventClosed()
test_case.full_signature: @Test /** again and similar but pass in a close event */ public void testEventClosed()
test_case.identifier: testEventClosed
test_case.invocations: setBucket setCiId setCiState setManifestId setSource setType setTimestamp put setCount setMetrics convert assertEquals getBucket assertEquals getCiState assertEquals getSource assertEquals getType assertEquals getMetrics equals getTimestamp equals getManifestId equals getCiId
test_case.modifiers: @Test /** again and similar but pass in a close event */ public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testEventClosed()
focal_class.file: sensor/src/main/java/com/oneops/sensor/util/EventConverter.java
focal_class.identifier: EventConverter
focal_class.class_method_signature: EventConverter.convert(OpsEvent oEvent)
focal_class.full_signature: public static OpsBaseEvent convert(OpsEvent oEvent)
focal_class.identifier: convert
focal_class.modifiers: public static
focal_class.parameters: (OpsEvent oEvent)
focal_class.return: OpsBaseEvent
focal_class.signature: OpsBaseEvent convert(OpsEvent oEvent)
focal_class.class_method_signature: EventConverter.convert(OpsCloseEvent oEvent)
focal_class.full_signature: public static OpsBaseEvent convert(OpsCloseEvent oEvent)
focal_class.identifier: convert
focal_class.modifiers: public static
focal_class.parameters: (OpsCloseEvent oEvent)
focal_class.return: OpsBaseEvent
focal_class.signature: OpsBaseEvent convert(OpsCloseEvent oEvent)
focal_method.body: public static OpsBaseEvent convert(OpsEvent oEvent) {
  		OpsBaseEvent bEvent = new OpsBaseEvent();
  		bEvent.setCiId(oEvent.getCiId());
  		bEvent.setBucket(oEvent.getBucket());
  		bEvent.setCiState(oEvent.getCiState());
  		bEvent.setName(oEvent.getName());
  		bEvent.setManifestId(oEvent.getManifestId());
  		bEvent.setSource(oEvent.getSource());
  		bEvent.setState(oEvent.getState());
  		bEvent.setType(oEvent.getType());
  		bEvent.setMetrics(oEvent.getMetrics());
  		bEvent.setTimestamp(oEvent.getTimestamp());
  		bEvent.setCount(oEvent.getCount());
  		bEvent.setStatus(oEvent.getStatus());
  		bEvent.setCoolOff(oEvent.getCoolOff());
  		return bEvent;
  	}
focal_method.class_method_signature: EventConverter.convert(OpsEvent oEvent)
focal_method.full_signature: public static OpsBaseEvent convert(OpsEvent oEvent)
focal_method.identifier: convert
focal_method.invocations: setCiId getCiId setBucket getBucket setCiState getCiState setName getName setManifestId getManifestId setSource getSource setState getState setType getType setMetrics getMetrics setTimestamp getTimestamp setCount getCount setStatus getStatus setCoolOff getCoolOff
focal_method.modifiers: public static
focal_method.parameters: (OpsEvent oEvent)
focal_method.return: OpsBaseEvent
focal_method.signature: OpsBaseEvent convert(OpsEvent oEvent)