private void Stop(object sender, RoutedEventArgs e)
        {
            _reader.Stop();
            var count = _reader.CoveredStatements.Count;

            CodeCoverageStore.Get.AddStatements(_reader.CoveredStatements, _reader.ObjectNameCache);

            StartButton.IsEnabled = true;
            StopButton.IsEnabled  = false;
            Status.Text           = "Added " + count + " statements to code coverage";

            ShowCodeMap(sender, e);
        }
Esempio n. 2
0
        private void Stop(object sender, RoutedEventArgs e)
        {
            try
            {
                _reader.Stop();
                var count = _reader.CoveredStatements.Count;

                CodeCoverageStore.Get.AddStatements(_reader.CoveredStatements, _reader.ObjectNameCache);

                StartButton.IsEnabled = true;
                StopButton.IsEnabled  = false;
                Status.Text           = "Added " + count + " statements to code coverage";

                ShowCodeMap(sender, e);
            }
            catch (Exception ex)
            {
                OutputPane.WriteMessageAndActivatePane("SSDTDevPack: CodeCoverage: Exception calling Stop: {0}", ex);
            }
        }