feat: 🎸 add pagination to host source table (#2854)

* feat: 🎸 add pagination to host source table

✅ Closes: https://hashicorp.atlassian.net/browse/ICU-17093

* test: 💍 add e2e tests for host source pagination

✅ Closes: https://hashicorp.atlassian.net/browse/ICU-17093

* refactor: 💡 change paginatedHosts to getter

✅ Closes: https://hashicorp.atlassian.net/browse/ICU-17093

* test: 💍 refactor e2e pagination test

✅ Closes: https://hashicorp.atlassian.net/browse/ICU-17093
This commit is contained in:
Cameron Perera authored and GitHub committed 2025-05-29 15:55:05 -05:00
1 parent 96f30d1b31
commit e3433ec1f7
5 files changed
+231 -5

No files matched your search

+21
View File
@@ -103,6 +103,27 @@ export default factory.extend({
},
}),
withManyHosts: trait({
afterCreate(target, server) {
const { scope } = target;
const hostCatalog = server.create('host-catalog', { scope });
const hosts = server.createList('host', 15, {
scope,
hostCatalog,
type: hostCatalog.type,
});
const hostSets = [
server.create('host-set', {
scope,
hostCatalog,
hosts,
type: hostCatalog.type,
}),
];
target.update({ hostSets });
},
}),
withTwoHosts: trait({
afterCreate(target, server) {
const { scope } = target;