Skip to content

Switch expression 100% coverage #903

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
sungam3r opened this issue Jul 19, 2020 · 5 comments
Closed

Switch expression 100% coverage #903

sungam3r opened this issue Jul 19, 2020 · 5 comments
Labels
bug Something isn't working tenet-coverage Issue related to possible incorrect coverage with repro Issue with repro

Comments

@sungam3r
Copy link

Please see danielpalme/ReportGenerator#362

@sungam3r
Copy link
Author

<?xml version="1.0" encoding="utf-8"?>
<coverage line-rate="1" branch-rate="0.0454" version="1.9" timestamp="1595165380" lines-covered="17" lines-valid="17" branches-covered="1" branches-valid="22">
  <sources>
    <source>C:\</source>
  </sources>
  <packages>
    <package name="Test" line-rate="1" branch-rate="0.0454" complexity="22">
      <classes>
        <class name="Test.MyClass" filename="Users\sunga\source\repos\Test\Test\MyClass.cs" line-rate="1" branch-rate="0.0454" complexity="22">
          <methods>
            <method name="Serialize" signature="(System.Object)" line-rate="1" branch-rate="0.0454" complexity="22">
              <lines>
                <line number="9" hits="1" branch="True" condition-coverage="4.54% (1/22)">
                  <conditions>
                    <condition number="6" type="jump" coverage="50%" />
                    <condition number="26" type="jump" coverage="0%" />
                    <condition number="46" type="jump" coverage="0%" />
                    <condition number="66" type="jump" coverage="0%" />
                    <condition number="86" type="jump" coverage="0%" />
                    <condition number="107" type="jump" coverage="0%" />
                    <condition number="128" type="jump" coverage="0%" />
                    <condition number="149" type="jump" coverage="0%" />
                    <condition number="170" type="jump" coverage="0%" />
                    <condition number="191" type="jump" coverage="0%" />
                    <condition number="212" type="jump" coverage="0%" />
                  </conditions>
                </line>
                <line number="10" hits="1" branch="False" />
                <line number="11" hits="1" branch="False" />
                <line number="12" hits="1" branch="False" />
                <line number="13" hits="1" branch="False" />
                <line number="14" hits="1" branch="False" />
                <line number="15" hits="1" branch="False" />
                <line number="16" hits="1" branch="False" />
                <line number="17" hits="1" branch="False" />
                <line number="18" hits="1" branch="False" />
                <line number="19" hits="1" branch="False" />
                <line number="20" hits="1" branch="False" />
                <line number="21" hits="1" branch="False" />
                <line number="22" hits="1" branch="False" />
                <line number="23" hits="1" branch="False" />
                <line number="24" hits="1" branch="False" />
                <line number="25" hits="1" branch="False" />
              </lines>
            </method>
          </methods>
          <lines>
            <line number="9" hits="1" branch="True" condition-coverage="4.54% (1/22)">
              <conditions>
                <condition number="6" type="jump" coverage="50%" />
                <condition number="26" type="jump" coverage="0%" />
                <condition number="46" type="jump" coverage="0%" />
                <condition number="66" type="jump" coverage="0%" />
                <condition number="86" type="jump" coverage="0%" />
                <condition number="107" type="jump" coverage="0%" />
                <condition number="128" type="jump" coverage="0%" />
                <condition number="149" type="jump" coverage="0%" />
                <condition number="170" type="jump" coverage="0%" />
                <condition number="191" type="jump" coverage="0%" />
                <condition number="212" type="jump" coverage="0%" />
              </conditions>
            </line>
            <line number="10" hits="1" branch="False" />
            <line number="11" hits="1" branch="False" />
            <line number="12" hits="1" branch="False" />
            <line number="13" hits="1" branch="False" />
            <line number="14" hits="1" branch="False" />
            <line number="15" hits="1" branch="False" />
            <line number="16" hits="1" branch="False" />
            <line number="17" hits="1" branch="False" />
            <line number="18" hits="1" branch="False" />
            <line number="19" hits="1" branch="False" />
            <line number="20" hits="1" branch="False" />
            <line number="21" hits="1" branch="False" />
            <line number="22" hits="1" branch="False" />
            <line number="23" hits="1" branch="False" />
            <line number="24" hits="1" branch="False" />
            <line number="25" hits="1" branch="False" />
          </lines>
        </class>
      </classes>
    </package>
  </packages>
</coverage>

@sungam3r
Copy link
Author

изображение

@tonerdo
Copy link
Collaborator

tonerdo commented Jul 19, 2020

@sungam3r maybe you can post the actual code as a comment so that it's easier to copy/paste a repro

@sungam3r
Copy link
Author

Full repro (actual code) here. Small C# project with one class + 1 test + bat script to perform coverage.

@MarcoRossignoli
Copy link
Collaborator

Dup of #936 I think it's an issue related to new pattern matching

@MarcoRossignoli MarcoRossignoli added bug Something isn't working tenet-coverage Issue related to possible incorrect coverage with repro Issue with repro labels Sep 2, 2020
@MarcoRossignoli MarcoRossignoli removed the untriaged To be investigated label Oct 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working tenet-coverage Issue related to possible incorrect coverage with repro Issue with repro
Projects
None yet
Development

No branches or pull requests

3 participants