[CSHARP-2927] Make the ReplaceX methods from class MongoCollectionBase<TDocument> virtual Created: 05/Feb/20 Updated: 28/Oct/23 Resolved: 09/Jul/20 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | API |
| Affects Version/s: | 2.10.1 |
| Fix Version/s: | 2.11.0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Lucian Naie | Assignee: | Mikalai Mazurenka (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
The class:
does not have the following methods as virtual:
Therefore they cannot be mocked with Moq in the unit tests. Is it possible to have them changed?
|
| Comments |
| Comment by Githook User [ 09/Jul/20 ] |
|
Author: {'name': 'Mikalai Mazurenka', 'email': 'mikalai.mazurenka@mongodb.com', 'username': 'MikalaiMazurenka'}Message: |
| Comment by Lucian Naie [ 05/Feb/20 ] |
|
Given that the ReplaceX methods that are using the UpdateOptions param were marked Obsolete, we're forced to use the ones with ReplaceOptions param. Sure, but then the unit testing needs some help from you. |