Skip to content
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

feat: mutator tests #17

Merged
merged 3 commits into from
Jun 11, 2021
Merged

feat: mutator tests #17

merged 3 commits into from
Jun 11, 2021

Conversation

aochmann
Copy link
Contributor

@aochmann aochmann commented Jun 8, 2021

What this PR does / why it's submitted / why we need it:

Added initial mutator test configuration. In separate PR we should setup configuration for output in PR as a comment / artifact. For now its not possible to specify output path (we will need to hack it).


Checklist:

  • My PR has a descriptive title (not a vague title like Needed this)
  • Title and all the commits follow commitlint guidelines
  • My PR targets the develop branch or appropriate release branch
  • I've placed the link to the corresponding Trello card or issue which this PR fixes/address below ⤵️

Fixes: ### ISSUE_OR_TRELLO_LINK ###

@aochmann aochmann self-assigned this Jun 8, 2021
@aochmann aochmann requested review from mzajkowski and trt June 8, 2021 12:48
@github-actions
Copy link
Contributor

github-actions bot commented Jun 8, 2021

Test Run for PR #17 (11)

Run Summary

Overall Result: ✔️ Pass
Pass Rate: 100%
Run Duration: 7s 552ms
Date: 2021-06-08 12:51:01 - 2021-06-08 12:51:09
Framework: .NETCoreApp,Version=v3.1
Total Tests: 50

✔️ Passed ❌ Failed ⚠️ Skipped
50 0 0
100% 0% 0%

Result Sets

Cogworks.Essentials.UnitTests.dll - 100%

Full Results
Result Test Duration
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValueAsync 48ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValueAsync 3ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValueAsync < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValueAsync 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_RemoveCacheKeyFromCacheKeysList_When_CacheItemExpired 1s 318ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: null) 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: 0) < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_RemoveCacheKeyFromCacheKeysList_When_RemoveItemFromCache 212ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ClearAllStartingWithPrefix 12ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_AddItems_When_LongThreadOperations(threadsSize: 1) 3ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_AddItems_When_LongThreadOperations(threadsSize: 2) 101ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_AddItems_When_LongThreadOperations(threadsSize: 10) 905ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Not_ThrowException_On_ClearingAllCache_When_NoItemsInCache 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ClearAllCache 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_RemoveCacheKeyFromCacheKeysList_When_CacheItemExpired_On_GetOrAddAsync 1s 311ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_True_When_CacheContainsItem 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_AddCacheItem_Without_CacheDuration 2ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Not_ThrowException_On_RemoveCacheItem_When_ItemNotInCache < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_DisposeCache < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValue < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValue < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValue < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_UpdateExistingItemValue 12ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_RemoveCacheKeyFromCacheKeysList_When_CacheItemExpired_On_GetOrAdd 1s 322ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Not_ThrowException_On_ClearingAllStartingWithPrefix_When_NoItemsInCache 2ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Not_ThrowException_On_TryGetValue_When_ItemIsNotConvertible 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_On_TryGetValue_When_ItemIsNotConvertible < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_On_TryGetValue_When_ItemIsNotConvertible < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_On_TryGetValue_When_ItemIsNotConvertible < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_On_TryGetValue_When_ItemIsNotConvertible < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_AddCacheItem_With_CacheDuration < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd_With_CacheDuration < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd_With_CacheDuration 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd_With_CacheDuration < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_When_CacheDoesNotContainsItem < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync_With_CacheDuration 66ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync_With_CacheDuration 57ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync_With_CacheDuration 63ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_True_On_TryGetValue_When_ItemExists 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ReturnDefault_When_CacheDoesNotContainKey < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ReturnDefault_When_CacheDoesNotContainKey < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ReturnDefault_When_CacheDoesNotContainKey < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_ReturnDefault_When_CacheDoesNotContainKey < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync 58ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync 61ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAddAsync 61ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_GetOrAdd < 1ms
✔️ Passed Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_RemoveCacheItem < 1ms

Run Messages

Informational

[xUnit.net 00:00:00.00] xUnit.net VSTest Adapter v2.4.3+1b45f5407b (64-bit .NET Core 3.1.7)
[xUnit.net 00:00:00.39]   Discovering: Cogworks.Essentials.UnitTests
[xUnit.net 00:00:00.45]   Discovered:  Cogworks.Essentials.UnitTests
[xUnit.net 00:00:00.46]   Starting:    Cogworks.Essentials.UnitTests
[xUnit.net 00:00:06.19]   Finished:    Cogworks.Essentials.UnitTests
Warning

[xUnit.net 00:00:00.45] Cogworks.Essentials.UnitTests: Skipping test case with duplicate ID '15e755b04f4d8a366703a4b236d7717d1656ad4a' ('Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: null)' and 'Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: null)')
[xUnit.net 00:00:00.45] Cogworks.Essentials.UnitTests: Skipping test case with duplicate ID '15e755b04f4d8a366703a4b236d7717d1656ad4a' ('Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: null)' and 'Cogworks.Essentials.UnitTests.Services.MemoryCacheServiceTests.Should_Return_False_TryGetValue_When_ItemNotExists(expectedOutput: null)')


Error


Created using Liquid Test Reports

Copy link

@mzajkowski mzajkowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good stuff mate! Awaiting blog coming out of it 🔥 Are we able to expose mutation tests in the action ^^ too?

@aochmann
Copy link
Contributor Author

aochmann commented Jun 9, 2021

Good stuff mate! Awaiting blog coming out of it 🔥 Are we able to expose mutation tests in the action ^^ too?

We can but it needs investigation as stryker.net does not have option to specify output path. I already created issue #18

@aochmann aochmann merged commit dff0105 into develop Jun 11, 2021
@aochmann aochmann deleted the feat/mutation-tests branch June 11, 2021 08:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants