2014-01-15 01:48:57 +08:00
|
|
|
integration("Discover Topics");
|
2013-06-14 03:08:42 +08:00
|
|
|
|
2013-06-21 03:02:02 +08:00
|
|
|
test("Default List", function() {
|
2013-07-05 04:19:59 +08:00
|
|
|
expect(2);
|
2013-06-14 03:08:42 +08:00
|
|
|
|
|
|
|
visit("/").then(function() {
|
|
|
|
ok(exists("#topic-list"), "The list of topics was rendered");
|
2013-06-21 03:02:02 +08:00
|
|
|
ok(exists('#topic-list .topic-list-item'), "has topics");
|
2013-06-14 03:08:42 +08:00
|
|
|
});
|
2013-07-05 04:19:59 +08:00
|
|
|
});
|
2013-06-14 03:08:42 +08:00
|
|
|
|
2013-07-05 04:19:59 +08:00
|
|
|
test("List one Category", function() {
|
|
|
|
expect(2);
|
|
|
|
|
|
|
|
visit("/category/bug").then(function() {
|
|
|
|
ok(exists("#topic-list"), "The list of topics was rendered");
|
|
|
|
ok(exists('#topic-list .topic-list-item'), "has topics");
|
|
|
|
});
|
2013-06-14 03:08:42 +08:00
|
|
|
});
|
|
|
|
|
2013-06-21 03:02:02 +08:00
|
|
|
test("Categories List", function() {
|
2013-07-05 04:19:59 +08:00
|
|
|
expect(1);
|
2013-06-21 03:02:02 +08:00
|
|
|
|
|
|
|
visit("/categories").then(function() {
|
2013-12-12 04:23:41 +08:00
|
|
|
ok(exists('.category'), "has a list of categories");
|
2013-06-21 03:02:02 +08:00
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
2013-06-14 03:08:42 +08:00
|
|
|
|