• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

AlamoEngine-Tools / PetroglyphTools / 8252849769

12 Mar 2024 05:02PM UTC coverage: 74.489% (+0.8%) from 73.737%
8252849769

Pull #387

github

web-flow
Merge f7095f970 into f4ad7514b
Pull Request #387: Use CommonUtilites as dependency

653 of 788 branches covered (82.87%)

Branch coverage included in aggregate %.

80 of 143 new or added lines in 17 files covered. (55.94%)

15 existing lines in 4 files now uncovered.

1645 of 2297 relevant lines covered (71.62%)

73.76 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/PG.Testing/Hashing/HashCodeCrc32HashingService.cs
1
using System;
2
using System.IO;
3
using System.Linq;
4
using System.Text;
5
using PG.Commons.Hashing;
6

7
namespace PG.Testing.Hashing;
8

9
public class HashCodeCrc32HashingService : ICrc32HashingService
10
{
11
    public Crc32 GetCrc32(string value, Encoding encoding)
12
    {
NEW
13
        return new Crc32(value.GetHashCode());
×
14
    }
15

16
    public Crc32 GetCrc32(ReadOnlySpan<byte> data)
17
    {
NEW
18
        var sum = data.ToArray().Sum(x => x);
×
NEW
19
        return new Crc32(sum.GetHashCode());
×
20
    }
21

22
    public Crc32 GetCrc32(Stream data)
23
    {
NEW
24
        var bytes = new byte[data.Length];
×
NEW
25
        return GetCrc32(bytes.AsSpan());
×
26
    }
27
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc