Exemplo n.º 1
0
        /// <summary>
        /// Sends the BeforeTestRunStart event and waits for result
        /// </summary>
        /// <returns>BeforeTestRunStartResult containing environment variables</returns>
        public BeforeTestRunStartResult SendBeforeTestRunStartAndGetResult(string settingsXml)
        {
            this.communicationManager.SendMessage(MessageType.BeforeTestRunStart, settingsXml);
            var message = this.communicationManager.ReceiveMessage();

            if (message.MessageType == MessageType.BeforeTestRunStartResult)
            {
                return(dataSerializer.DeserializePayload <BeforeTestRunStartResult>(message));
            }

            return(null);
        }
Exemplo n.º 2
0
        void OnTestCasesFound(Message message)
        {
            var tests = dataSerializer.DeserializePayload <IEnumerable <TestCase> > (message);

            discoveredTests.Add(tests);
        }