### Question:
LearningRule implements Serializable { public synchronized boolean isStopped() { return this.stopLearning; } LearningRule(); void setTrainingSet(DataSet trainingSet); DataSet getTrainingSet(); NeuralNetwork getNeuralNetwork(); void setNeuralNetwork(NeuralNetwork neuralNetwork); synchronized void stopLearning(); synchronized boolean isStopped(); synchronized void addListener(LearningEventListener listener); synchronized void removeListener(LearningEventListener listener); abstract void learn(DataSet trainingSet);  }### Answer:
@Test public void testIsStopped() { assertFalse(testableLearningRule.isStopped()); testableLearningRule.stopLearning(); assertTrue(testableLearningRule.isStopped()); }