A short dataset
()
| 677 | |
| 678 | |
| 679 | def datasource1_direct(): |
| 680 | """A short dataset""" |
| 681 | schema = datasource1_schema() |
| 682 | |
| 683 | class Generator: |
| 684 | def __init__(self): |
| 685 | self.n = 3 |
| 686 | |
| 687 | def __call__(self, ctx): |
| 688 | if self.n == 0: |
| 689 | batch = _record_batch_from_iters(schema, [], []) |
| 690 | else: |
| 691 | self.n -= 1 |
| 692 | batch = _record_batch_for_range(schema, self.n) |
| 693 | return batch.to_struct_array() |
| 694 | return lambda ctx: Generator() |
| 695 | |
| 696 | |
| 697 | def datasource1_generator(): |
nothing calls this directly
no test coverage detected