Sobes.tech

Do czego służy IDisposable?

Middle+
130

Czym jest struct i czym różni się od klasy?

Middle+
125

Przegląd: test CalendarService.cs: public class CalendarService { public bool IsWorkingDay() { switch (DateTime.Now.DayOfWeek) { case DayOfWeek.Saturday: case DayOfWeek.Sunday: return false; default: return true; } } } CalendarServiceTests.cs: public class CalendarServiceTests { [Fact] public void IsWorkingDay_Always_ReturnsTrue() { // Przygotuj var calendarService = new CalendarService(); // Działanie var actual = calendarService.IsWorkingDay(); // Assercja Assert.True(actual); } }

Middle+
122
/3