/// <summary> /// Start Dicom data receiver on a given port and check it is listening. /// </summary> /// <param name="dicomDataReceiver">Dicom data receiver.</param> /// <param name="port">Port.</param> protected void StartDicomDataReceiver( ListenerDataReceiver dicomDataReceiver, int port) { var started = dicomDataReceiver.StartServer(port, BuildAcceptedSopClassesAndTransferSyntaxes, TimeSpan.FromSeconds(2)); Assert.IsTrue(started); Assert.IsTrue(dicomDataReceiver.IsListening); }
/// <summary> /// Start Dicom data receiver on a given port and check it is listening. /// </summary> /// <param name="dicomDataReceiver">Dicom data receiver.</param> /// <param name="port">Port.</param> protected static void StartDicomDataReceiver( ListenerDataReceiver dicomDataReceiver, int port) { dicomDataReceiver = dicomDataReceiver ?? throw new ArgumentNullException(nameof(dicomDataReceiver)); var started = dicomDataReceiver.StartServer(port, BuildAcceptedSopClassesAndTransferSyntaxes, TimeSpan.FromSeconds(2)); Assert.IsTrue(started); Assert.IsTrue(dicomDataReceiver.IsListening); }