[Solved]Need C One Already Answered Chegg Java Please Answer Question Question Already Answered Wr Q37090536
Need it in C# (the one already answered onchegg in java.)

Please answer the question below: (the above question is alreadyanswered)
Write unit tests for the above class. Be sure to have 100% codecoverage in your tests.
Answer of first two parts is:
public class Cup { private int _maxCapacityInML; private int _actualLiquidContentsInML; public Cup(int maxCapacityInML) { this._maxCapacityInML = maxCapacityInML; } public int getActualLiquidContentsInML() { return _actualLiquidContentsInML; } public void addLiquidInMLs(int volumeToAddInMLs) { if (_actualLiquidContentsInML + volumeToAddInMLs > _maxCapacityInML) { throw new RuntimeException(); } _actualLiquidContentsInML += volumeToAddInMLs; } public void pour(int volumeToPourInMLs) { if (_actualLiquidContentsInML < volumeToPourInMLs) { throw new RuntimeException(); } _actualLiquidContentsInML -= volumeToPourInMLs; }}Given the following UML, write the class Cup ImaxCapacityInML: int I- _actualLiquidContentsInML int pntinn +CupC maxCapacityInMLint I + getActualLiquidContentInMLO : int + addLiquidInMLsC volumeToAddInMLsint) I pour volumeToPourInMLs : int ) When addingLiquids, raise an exception if the new actualLiquidContentInML wiiï be > than the max capacity When pouring, raise an exception if there are not enough actualLiquidCOntentInML to pour Show transcribed image text Given the following UML, write the class Cup ImaxCapacityInML: int I- _actualLiquidContentsInML int pntinn +CupC maxCapacityInMLint I + getActualLiquidContentInMLO : int + addLiquidInMLsC volumeToAddInMLsint) I pour volumeToPourInMLs : int ) When addingLiquids, raise an exception if the new actualLiquidContentInML wiiï be > than the max capacity When pouring, raise an exception if there are not enough actualLiquidCOntentInML to pour
Expert Answer
Answer to Need it in C# (the one already answered on chegg in java.) Please answer the question below: (the above question is alre… . . .
OR

