Java 用junit编写一个测试用例
对于这种SetScene方法,用Junit编写测试用例的正确方法是什么Java 用junit编写一个测试用例,java,junit,junit4,Java,Junit,Junit4,对于这种SetScene方法,用Junit编写测试用例的正确方法是什么 public static void SetScene(int index){ root.getChildren().remove(liste.get(indexcurrent)); root.getChildren().add(liste.get(index)); indexcurrent=index; if (index == 3) { try { root
public static void SetScene(int index){
root.getChildren().remove(liste.get(indexcurrent));
root.getChildren().add(liste.get(index));
indexcurrent=index;
if (index == 3) {
try {
root.setCenter(liste.get(index));
}
catch (Exception InvocationTargetException){
}
}
}
我可能会这样做
根目录
和子目录SetScene(x)
root
和currentindex
是否有所需的值和状态你试过什么了吗?你到底被困在哪里了?没有。实际上我不明白。对不起,我先答错了。然后我改正了。