Test basic bulk create operation.
(db_truncate)
| 18 | |
| 19 | @pytest.mark.asyncio |
| 20 | async def test_bulk_create(db_truncate): |
| 21 | """Test basic bulk create operation.""" |
| 22 | await UniqueName.bulk_create([UniqueName() for _ in range(1000)]) |
| 23 | all_ = await UniqueName.all().values("id", "name") |
| 24 | inc = all_[0]["id"] |
| 25 | assert_list_sort_equal( |
| 26 | all_, |
| 27 | [{"id": val + inc, "name": None} for val in range(1000)], |
| 28 | sorted_key="id", |
| 29 | ) |
| 30 | |
| 31 | |
| 32 | @requireCapability(dialect=NotEQ("mssql")) |
nothing calls this directly
no test coverage detected
searching dependent graphs…