Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Test setup.
- var shop = new CandyShopStub(new DummyCandy());
- // CandyShopStub.cs
- class CandyShopStub : ICandyShop {
- private readonly ICandy _candy;
- public CandyShopStub(ICandy candy) {
- _candy = candy;
- }
- public ICandy GetTopSellingCandy() {
- return _candy;
- }
- }
- // DummyCandy.cs
- class DummyCandy : ICandy {}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement