| 288 | const key = queryKey() |
| 289 | |
| 290 | @Component({ |
| 291 | template: ` |
| 292 | <div>status: {{ query.status() }}</div> |
| 293 | <div>data: {{ query.data() ?? 'none' }}</div> |
| 294 | <div>isPending: {{ query.isPending() }}</div> |
| 295 | <div>isFetching: {{ query.isFetching() }}</div> |
| 296 | <div>isFetched: {{ query.isFetched() }}</div> |
| 297 | <div>isSuccess: {{ query.isSuccess() }}</div> |
| 298 | `, |
| 299 | }) |
| 300 | class Page { |
| 301 | readonly query = injectQuery(() => ({ |
| 302 | queryKey: key, |
| 303 | queryFn: () => sleep(10).then(() => 'result2'), |
| 304 | })) |
| 305 | } |
| 306 | |
| 307 | const rendered = await render(Page) |
| 308 |
nothing calls this directly
no test coverage detected