2018-06-12 12:47:03 +02:00
|
|
|
import { acceptance } from "helpers/qunit-helpers";
|
2018-04-25 10:28:41 +02:00
|
|
|
|
|
|
|
acceptance("Dashboard Next", {
|
|
|
|
loggedIn: true
|
|
|
|
});
|
|
|
|
|
2018-05-03 15:41:41 +02:00
|
|
|
QUnit.test("Visit dashboard next page", assert => {
|
2018-05-14 15:41:19 +10:00
|
|
|
visit("/admin");
|
2018-04-25 10:28:41 +02:00
|
|
|
|
|
|
|
andThen(() => {
|
2018-06-12 12:47:03 +02:00
|
|
|
assert.ok($(".dashboard-next").length, "has dashboard-next class");
|
2018-05-17 22:44:33 +02:00
|
|
|
|
2018-06-12 12:47:03 +02:00
|
|
|
assert.ok($(".dashboard-mini-chart.signups").length, "has a signups chart");
|
|
|
|
|
|
|
|
assert.ok($(".dashboard-mini-chart.posts").length, "has a posts chart");
|
|
|
|
|
|
|
|
assert.ok(
|
|
|
|
$(".dashboard-mini-chart.dau_by_mau").length,
|
|
|
|
"has a dau_by_mau chart"
|
|
|
|
);
|
|
|
|
|
|
|
|
assert.ok(
|
|
|
|
$(".dashboard-mini-chart.daily_engaged_users").length,
|
|
|
|
"has a daily_engaged_users chart"
|
|
|
|
);
|
|
|
|
|
|
|
|
assert.ok(
|
|
|
|
$(".dashboard-mini-chart.new_contributors").length,
|
|
|
|
"has a new_contributors chart"
|
|
|
|
);
|
|
|
|
|
|
|
|
assert.equal(
|
|
|
|
$(".section.dashboard-problems .problem-messages ul li:first-child")
|
|
|
|
.html()
|
|
|
|
.trim(),
|
|
|
|
"Houston...",
|
|
|
|
"displays problems"
|
|
|
|
);
|
2018-04-25 10:28:41 +02:00
|
|
|
});
|
|
|
|
});
|