コントローラー クラスの 1 つに以下のコードがあります。
initialize:function(){
var myView = new MyViewClass({ vent : this.getParent().getVent(); });
..... other code of the initialize method
},
getParent(){
.... returns the parent of this class
}
getParent()メソッドはこのクラスの親を返し、親のgetVent()メソッドは親のベントを返します。initializeメソッドを実行してテストできるように、スパイを使用するにはどうすればよいですか。