This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/tests/unit/models/group-test.js
Jarek Radosz 1b52cdedb1
DEV: Move more tests into modules (#11119)
Models, services, mixins, utilities, and most of the controllers
2020-11-05 20:23:28 +01:00

23 lines
522 B
JavaScript

import { test, module } from "qunit";
import Group from "discourse/models/group";
module("Unit | Model | group", function () {
test("displayName", function (assert) {
const group = Group.create({ name: "test", display_name: "donkey" });
assert.equal(
group.get("displayName"),
"donkey",
"it should return the display name"
);
group.set("display_name", null);
assert.equal(
group.get("displayName"),
"test",
"it should return the group's name"
);
});
});