给定一个类
public class BoolTest {
private Boolean aBoolean;
private String aString;
public Boolean isABoolean() {
return aBoolean;
}
public void setABoolean(Boolean value) {
this.aBoolean = value;
}
public String getAString() {
return aString;
}
public void setAString(String aString) {
this.aString = aString;
}
}
测试
(def example (BoolTest.))
(defn run-test []
(do
(-> example
(.setABoolean true))
(-> example
(.setAString "something"))
(from-java example)))
***** 实际
(test/run-test) => {:AString "something"}
**** 期望
(test/run-test) => {:AString "something" :ABoolean true}