Improve thread list view tests
An obsolete test case was passing because the assertions were too weak, so the assertions are improved and the test case removed.
This commit is contained in:
@@ -475,6 +475,7 @@ describe "DiscussionThreadListView", ->
|
||||
testSelectionRequest = (callback, itemText) ->
|
||||
setupAjax(callback)
|
||||
$(".forum-nav-browse-title:contains(#{itemText})").click()
|
||||
expect($.ajax).toHaveBeenCalled()
|
||||
|
||||
it "should get all discussions", ->
|
||||
testSelectionRequest(
|
||||
@@ -482,15 +483,6 @@ describe "DiscussionThreadListView", ->
|
||||
"All"
|
||||
)
|
||||
|
||||
it "should get flagged threads", ->
|
||||
testSelectionRequest(
|
||||
(params) ->
|
||||
expect(params.url.path()).toEqual(DiscussionUtil.urlFor("search"))
|
||||
expect(params.data.flagged).toEqual(true)
|
||||
,
|
||||
"Flagged"
|
||||
)
|
||||
|
||||
it "should get followed threads", ->
|
||||
testSelectionRequest(
|
||||
(params) ->
|
||||
|
||||
Reference in New Issue
Block a user