mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-08-31 19:08:29 +00:00
- Introduced `FakeCrestronEnvironment` and `FakeEthernetHelper` for testing purposes. - Implemented `InMemoryCrestronDataStore` to facilitate unit tests for data storage. - Created `DebugServiceTests` to validate the behavior of debug-related services. - Added project files for unit tests targeting .NET 9.0 with necessary dependencies. - Developed production adapters (`CrestronConsoleAdapter`, `CrestronDataStoreAdapter`, `CrestronEnvironmentAdapter`, `CrestronEthernetAdapter`) to interface with the Crestron SDK. - Updated `Debug` class to utilize injected service abstractions instead of direct SDK calls. - Enhanced `ControlSystem` initialization to register service adapters before usage.
16 lines
640 B
C#
16 lines
640 B
C#
namespace PepperDash.Core.Abstractions;
|
|
|
|
/// <summary>
|
|
/// Abstracts <c>Crestron.SimplSharp.CrestronEthernetHelper</c> to allow unit testing
|
|
/// without the Crestron SDK.
|
|
/// </summary>
|
|
public interface IEthernetHelper
|
|
{
|
|
/// <summary>
|
|
/// Returns a network parameter string for the specified adapter.
|
|
/// </summary>
|
|
/// <param name="parameter">The parameter to retrieve.</param>
|
|
/// <param name="ethernetAdapterId">Ethernet adapter index (0 = LAN A).</param>
|
|
/// <returns>String value of the requested parameter.</returns>
|
|
string GetEthernetParameter(EthernetParameterType parameter, short ethernetAdapterId);
|
|
}
|