UI: stabilize replication tests (#28384)

* Add specificity to replication title selectors

* Use specific selectors for replication titles in tests
This commit is contained in:
Chelsea Shaw
2024-09-12 14:50:37 -05:00
committed by GitHub
parent 84c58f66bb
commit 1c16994bc3
7 changed files with 36 additions and 28 deletions

View File

@@ -62,11 +62,11 @@ module('Integration | Component | replication-page', function (hooks) {
await render(
hbs`<ReplicationPage @model={{this.model}} as |Page|><Page.header @showTabs={{true}} /></ReplicationPage>`
);
await waitFor('[data-test-replication-title]');
await waitFor('[data-test-replication-title="dr"]');
// Title has spaces and newlines, so we can't use hasText because it won't match exactly
assert.dom('[data-test-replication-title]').includesText('Disaster Recovery');
assert.dom('[data-test-replication-title="dr"]').includesText('Disaster Recovery');
this.set('model', { ...MODEL, replicationMode: 'performance' });
await settled();
assert.dom('[data-test-replication-title]').includesText('Performance');
assert.dom('[data-test-replication-title="performance"]').includesText('Performance');
});
});