@Test public void getAssoc() throws Exception { TouchSensor<Void> touchSensor = TouchSensor.make( TouchSensorMode.TOUCH, SensorPort.S1, BlocklyBlockProperties.make("1", "1", false, false, false, false, false, true, false), null); SensorExpr<Void> sensorExpr = SensorExpr.make(touchSensor); Assert.assertEquals(Assoc.NONE, sensorExpr.getAssoc()); }
@Test public void getSensor() throws Exception { TouchSensor<Void> touchSensor = TouchSensor.make( TouchSensorMode.TOUCH, SensorPort.S1, BlocklyBlockProperties.make("1", "1", false, false, false, false, false, true, false), null); SensorExpr<Void> sensorExpr = SensorExpr.make(touchSensor); String a = "TouchSensor [port=S1]"; Assert.assertEquals(a, sensorExpr.getSens().toString()); }