package sia.knights;
import org.junit.Test;
public class DamselRescuingKnight implements Knight {
private RescueDamselQuest quest;
public DamselRescuingKnight() {
this.quest = new RescueDamselQuest();
}
@Test
public void embarkOnQuest() {
quest.embark();
}
}
————————————————————————————————————————————————
package sia.knights;
public class RescueDamselQuest implements Quest {
public void embark() {
System.out.println("Embarking on a quest to rescue the damsel.");
}
}
———————————————————————————————————————————————
package sia.knights;
public interface Quest {
void embark();
}
求大佬解答这种情况为啥Junit会报错?
第一次这样用Junit 不懂 求指教
qq_我就喵了个咪呀_0
you_name
零煜
相关分类