私はこのコントローラーメソッドを持っています:
[GET("/whatever/list")]
public ActionResult Index(string sortby, string order)
MvcContribルートテストでテストしようとしています。
"~/whatever/list".ShouldMapTo<MyController>(c => c.Index(string.Empty, string.Empty));
"~/whatever/list?sortby=type&order=desc".ShouldMapTo<MyController>(c => c.Index("type", "desc"));
ただし、このエラーが返されます。
失敗:MvcContrib.TestHelper.AssertionException:パラメーター'sortby'の値が一致しませんでした:期待される''が''でした; 'sortby'という名前のルートコンテキストアクションパラメータに値が見つかりません-一致するルートに'sortby'というトークンが含まれていますか?
私は何が欠けていますか?