DEV: global s/this.get\("(\w+)"\)/this.$1 (#7592)

This commit is contained in:
Joffrey JAFFEUX
2019-05-27 10:15:39 +02:00
committed by GitHub
parent 170c66c190
commit bfea922167
389 changed files with 2448 additions and 2460 deletions

View File

@ -12,13 +12,13 @@ componentTest("with value", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
2
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"feature"
@ -30,10 +30,10 @@ componentTest("with excludeCategoryId", {
template: "{{category-chooser excludeCategoryId=2}}",
async test(assert) {
await this.get("subject").expand();
await this.subject.expand();
assert.notOk(
this.get("subject")
this.subject
.rowByValue(2)
.exists()
);
@ -44,37 +44,37 @@ componentTest("with scopedCategoryId", {
template: "{{category-chooser scopedCategoryId=2}}",
async test(assert) {
await this.get("subject").expand();
await this.subject.expand();
assert.equal(
this.get("subject")
this.subject
.rowByIndex(0)
.title(),
"Discussion about features or potential features of Discourse: how they work, why they work, etc."
);
assert.equal(
this.get("subject")
this.subject
.rowByIndex(0)
.value(),
2
);
assert.equal(
this.get("subject")
this.subject
.rowByIndex(1)
.title(),
"My idea here is to have mini specs for features we would like built but have no bandwidth to build"
);
assert.equal(
this.get("subject")
this.subject
.rowByIndex(1)
.value(),
26
);
assert.equal(this.get("subject").rows().length, 2);
assert.equal(this.subject.rows().length, 2);
await this.get("subject").fillInFilter("dev");
await this.subject.fillInFilter("dev");
assert.equal(this.get("subject").rows().length, 3);
assert.equal(this.subject.rows().length, 3);
}
});
@ -87,13 +87,13 @@ componentTest("with allowUncategorized=null", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"category"
@ -110,13 +110,13 @@ componentTest("with allowUncategorized=null rootNone=true", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"category"
@ -135,13 +135,13 @@ componentTest("with disallowed uncategorized, rootNone and rootNoneLabel", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"category"
@ -158,13 +158,13 @@ componentTest("with allowed uncategorized", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"uncategorized"
@ -181,13 +181,13 @@ componentTest("with allowed uncategorized and rootNone", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"(no category)"
@ -206,13 +206,13 @@ componentTest("with allowed uncategorized rootNone and rootNoneLabel", {
test(assert) {
assert.equal(
this.get("subject")
this.subject
.header()
.value(),
null
);
assert.equal(
this.get("subject")
this.subject
.header()
.title(),
"root none label"