Skip to content

Commit 79d2b80

Browse files
committed
remove test
1 parent d6866ef commit 79d2b80

File tree

1 file changed

+0
-74
lines changed

1 file changed

+0
-74
lines changed

packages/host/tests/integration/components/card-basics-test.gts

-74
Original file line numberDiff line numberDiff line change
@@ -1970,80 +1970,6 @@ module('Integration | card-basics', function (hooks) {
19701970
assert.dom('[data-test-subclass2]').hasText('SubClass2 New Name 2');
19711971
});
19721972

1973-
test('can re-renders a card with a polymorphic "containsMany" field', async function (assert) {
1974-
class Person extends FieldDef {
1975-
@field firstName = contains(StringField);
1976-
}
1977-
1978-
class Employee extends Person {
1979-
@field department = contains(StringField);
1980-
static embedded = class Embedded extends Component<typeof this> {
1981-
<template>
1982-
<div data-test-employee-firstName><@fields.firstName /></div>
1983-
<div data-test-employee-department><@fields.department /></div>
1984-
</template>
1985-
};
1986-
}
1987-
1988-
class Customer extends Person {
1989-
@field billAmount = contains(NumberField);
1990-
static embedded = class Embedded extends Component<typeof this> {
1991-
<template>
1992-
<div data-test-customer-firstName><@fields.firstName /></div>
1993-
<div data-test-customer-billAmount><@fields.billAmount /></div>
1994-
</template>
1995-
};
1996-
}
1997-
1998-
class Group extends CardDef {
1999-
@field people = containsMany(Person);
2000-
static isolated = class Isolated extends Component<typeof this> {
2001-
setSubclass = () => {
2002-
debugger;
2003-
let a = this.args.model.people![0];
2004-
this.args.model.people = [
2005-
a,
2006-
new Customer({
2007-
firstName: 'Hi',
2008-
billAmount: 1000000,
2009-
}),
2010-
];
2011-
};
2012-
<template>
2013-
<button {{on 'click' this.setSubclass}} data-test-set-subclass>Set
2014-
Subclass From Outside</button>
2015-
<div><@fields.people /></div>
2016-
</template>
2017-
};
2018-
}
2019-
2020-
loader.shimModule(`${testRealmURL}test-cards`, {
2021-
Person,
2022-
Employee,
2023-
Customer,
2024-
Group,
2025-
});
2026-
2027-
let group = new Group({
2028-
people: [
2029-
new Employee({
2030-
firstName: 'Mango',
2031-
department: 'begging',
2032-
}),
2033-
new Customer({
2034-
firstName: 'Van Gogh',
2035-
billAmount: 100,
2036-
}),
2037-
],
2038-
});
2039-
await renderCard(loader, group, 'isolated');
2040-
assert.dom('[data-test-employee-firstName]').containsText('Mango');
2041-
assert.dom('[data-test-employee-department]').containsText('begging');
2042-
assert.dom('[data-test-customer-firstName]').containsText('Van Gogh');
2043-
assert.dom('[data-test-customer-billAmount]').containsText('100');
2044-
await this.pauseTest();
2045-
});
2046-
20471973
test('rerender when a primitive field changes', async function (assert) {
20481974
class Person extends CardDef {
20491975
@field firstName = contains(StringField);

0 commit comments

Comments
 (0)