(self)
| 128 | self.coll.bulk_write([]) |
| 129 | |
| 130 | def test_insert(self): |
| 131 | expected = { |
| 132 | "nMatched": 0, |
| 133 | "nModified": 0, |
| 134 | "nUpserted": 0, |
| 135 | "nInserted": 1, |
| 136 | "nRemoved": 0, |
| 137 | "upserted": [], |
| 138 | "writeErrors": [], |
| 139 | "writeConcernErrors": [], |
| 140 | } |
| 141 | |
| 142 | result = self.coll.bulk_write([InsertOne({})]) |
| 143 | self.assertEqualResponse(expected, result.bulk_api_result) |
| 144 | self.assertEqual(1, result.inserted_count) |
| 145 | self.assertEqual(1, self.coll.count_documents({})) |
| 146 | |
| 147 | def _test_update_many(self, update): |
| 148 | expected = { |
nothing calls this directly
no test coverage detected