Skip to content

fix: allow count by status filter to be null #709

fix: allow count by status filter to be null

fix: allow count by status filter to be null #709

This check has been archived and is scheduled for deletion. Learn more about checks retention
GitHub Actions / Test - windows Adaptors/MongoDB/tests succeeded Jul 25, 2023 in 0s

Test - windows Adaptors/MongoDB/tests ✅

Tests passed successfully

✅ Adaptors/MongoDB/tests/TestResults/test-results.trx

255 tests were completed in 391s with 255 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
ArmoniK.Core.Adapters.MongoDB.Tests.AuthenticationTableTest 32✅ 31ms
ArmoniK.Core.Adapters.MongoDB.Tests.BsonSerializerTest 13✅ 616ms
ArmoniK.Core.Adapters.MongoDB.Tests.ExpressionsBuildersFieldFilterExpressionTests 20✅ 52ms
ArmoniK.Core.Adapters.MongoDB.Tests.IndexTest 4✅ 6s
ArmoniK.Core.Adapters.MongoDB.Tests.InjectionTests 21✅ 77ms
ArmoniK.Core.Adapters.MongoDB.Tests.ObjectStorageTests 7✅ 10s
ArmoniK.Core.Adapters.MongoDB.Tests.PartitionTableTests 22✅ 22s
ArmoniK.Core.Adapters.MongoDB.Tests.ResultTableTests 30✅ 31s
ArmoniK.Core.Adapters.MongoDB.Tests.ResultWatcherTests 4✅ 32s
ArmoniK.Core.Adapters.MongoDB.Tests.SessionProviderTests 2✅ 1s
ArmoniK.Core.Adapters.MongoDB.Tests.SessionTableTests 18✅ 190s
ArmoniK.Core.Adapters.MongoDB.Tests.TaskTableTests 79✅ 74s
ArmoniK.Core.Adapters.MongoDB.Tests.TaskWatcherTests 3✅ 9s

✅ ArmoniK.Core.Adapters.MongoDB.Tests.AuthenticationTableTest

✅ GetIdentityFromCnAndFingerprintShouldFail("CNUser1","Fingerprint2")
✅ GetIdentityFromCnAndFingerprintShouldFail("CNUser6","Fingerprint6")
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser1","Fingerprint1",0)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser2","Fingerprint2",1)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser2","Fingerprint3",3)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser2","Fingerprint7",1)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser2","FingerprintDontCare",3)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser3","Fingerprint3",1)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser4","Fingerprint4",2)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUser5","Fingerprint5",3)
✅ GetIdentityFromCnAndFingerprintShouldSucceed("CNUserCommon","FingerprintDontCare",2)
✅ GetIdentityFromIdShouldFail("UserIdDontExist")
✅ GetIdentityFromIdShouldSucceed(0,"User1")
✅ GetIdentityFromIdShouldSucceed(1,"User2")
✅ GetIdentityFromNameShouldFail("UserDontExist")
✅ GetIdentityFromNameShouldSucceed("User1",0)
✅ GetIdentityFromNameShouldSucceed("User2",1)
✅ InitShouldSucceed
✅ UserHasAllClaimsOfItsRoles(UserData { UserId = 66be5c6866be5c6866be5c68, Username = User2, Roles = System.String[] })
✅ UserHasAllClaimsOfItsRoles(UserData { UserId = 6734215f6734215f6734215f, Username = User4, Roles = System.String[] })
✅ UserHasAllClaimsOfItsRoles(UserData { UserId = 7a5193cf7a5193cf7a5193cf, Username = User1, Roles = System.String[] })
✅ UserHasAllClaimsOfItsRoles(UserData { UserId = a15de043a15de043a15de043, Username = User5, Roles = System.String[] })
✅ UserHasAllClaimsOfItsRoles(UserData { UserId = d035665bd035665bd035665b, Username = User3, Roles = System.String[] })
✅ UserHasClaimShouldMatch("User1","category1:name1",True)
✅ UserHasClaimShouldMatch("User1","category1:name2",True)
✅ UserHasClaimShouldMatch("User1","category1:name3",False)
✅ UserHasClaimShouldMatch("User2","category1:name2:all",True)
✅ UserHasClaimShouldMatch("User2","category1:name2",True)
✅ UserHasRoleShouldMatch("User1","Role1",True)
✅ UserHasRoleShouldMatch("User1","Role2",False)
✅ UserHasRoleShouldMatch("User2","Role1",True)
✅ UserHasRoleShouldMatch("User2","RoleDontExist",False)

✅ ArmoniK.Core.Adapters.MongoDB.Tests.BsonSerializerTest

✅ InitializeAuthDataModelMapping
✅ InitializeResultDataModelMapping
✅ InitializeRoleDataModelMapping
✅ InitializeSessionDataModelMapping
✅ InitializeTaskDataModelMapping
✅ InitializeUserDataModelMapping
✅ SerializeAuthDataModel
✅ SerializeResultDataModel
✅ SerializeRoleDataModel
✅ SerializeSessionDataModel
✅ SerializeTaskDataModel
✅ SerializeUserAuthenticationResult
✅ SerializeUserDataModel

✅ ArmoniK.Core.Adapters.MongoDB.Tests.ExpressionsBuildersFieldFilterExpressionTests

✅ ShouldExcludeMultipleStatus
✅ ShouldExcludeMultipleTask
✅ ShouldExcludeSession
✅ ShouldExcludeStatus
✅ ShouldExcludeTask
✅ ShouldIncludeOtherMultipleStatus
✅ ShouldIncludeOtherMultipleTask
✅ ShouldIncludeOtherSession
✅ ShouldIncludeOtherStatus
✅ ShouldIncludeOtherTask
✅ ShouldRecognizeMultipleStatus
✅ ShouldRecognizeMultipleTask
✅ ShouldRecognizeSession
✅ ShouldRecognizeStatus
✅ ShouldRecognizeTask
✅ ShouldRejectOtherMultipleStatus
✅ ShouldRejectOtherMultipleTask
✅ ShouldRejectOtherSession
✅ ShouldRejectOtherStatus
✅ ShouldRejectOtherTask

✅ ArmoniK.Core.Adapters.MongoDB.Tests.IndexTest

✅ CombinedIndexCreationShouldSucceed
✅ GenericIndexCreationShouldSucceed
✅ IndexCreation2ShouldSucceed
✅ IndexCreationShouldSucceed

✅ ArmoniK.Core.Adapters.MongoDB.Tests.InjectionTests

✅ BuildObjectStorage
✅ BuildTableStorage
✅ MongoDbOptionsNotNull
✅ MongoDbOptionsValueNotNull
✅ ObjectOptionsNotNull
✅ ObjectStorageFactoryHasBindingToObjectStorage
✅ ReadMongoDbCaFile
✅ ReadMongoDbCredentialsPath
✅ ReadMongoDbDatabaseName
✅ ReadMongoDbDataRetention
✅ ReadMongoDbHost
✅ ReadMongoDbPassword
✅ ReadMongoDbPort
✅ ReadMongoDbTls
✅ ReadMongoDbUser
✅ ReadObjectChunkSize
✅ ReadTablePollingMaxDelay
✅ ReadTablePollingMinDelay
✅ TableOptionsNotNull
✅ TableStorageHasPollingDelayMax
✅ TableStorageHasPollingDelayMin

✅ ArmoniK.Core.Adapters.MongoDB.Tests.ObjectStorageTests

✅ AddValuesAsyncWithoutChunkShouldWork
✅ DeleteKeysAndGetValuesAsyncShouldFail
✅ EmptyPayload
✅ GetValuesAsyncShouldFail
✅ InitShouldSucceed
✅ Payload2ShouldBeEqual
✅ PayloadShouldBeEqual

✅ ArmoniK.Core.Adapters.MongoDB.Tests.PartitionTableTests

✅ ArePartitionExistingAsyncShouldReturnFalse
✅ ArePartitionExistingAsyncShouldSucceed
✅ DeleteAlreadyDeletedTaskAsyncShouldThrowException
✅ DeleteTaskAsyncShouldThrowException
✅ InitShouldSucceed
✅ ListPartitionFilter({ "array": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PARENT_PARTITION_IDS" } }, "value": "AnotherParentPartitionId", "operator": "FILTER_ARRAY_OPERATOR_CONTAINS" } } false)
✅ ListPartitionFilter({ "array": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PARENT_PARTITION_IDS" } }, "value": "AnotherParentPartitionId", "operator": "FILTER_ARRAY_OPERATOR_NOT_CONTAINS" } } true)
✅ ListPartitionFilter({ "array": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PARENT_PARTITION_IDS" } }, "value": "ParentPartitionId", "operator": "FILTER_ARRAY_OPERATOR_CONTAINS" } } true)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_POD_MAX" } }, "value": "13", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } true)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_POD_MAX" } }, "value": "2", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } false)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_POD_RESERVED" } }, "value": "1", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } true)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_POD_RESERVED" } }, "value": "2", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } false)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PREEMPTION_PERCENTAGE" } }, "value": "2", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } false)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PREEMPTION_PERCENTAGE" } }, "value": "50", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } true)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PRIORITY" } }, "value": "1", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } true)
✅ ListPartitionFilter({ "number": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_PRIORITY" } }, "value": "2", "operator": "FILTER_NUMBER_OPERATOR_EQUAL" } } false)
✅ ListPartitionFilter({ "string": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_ID" } }, "value": "PartitionId_false", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } false)
✅ ListPartitionFilter({ "string": { "field": { "partitionRawField": { "field": "PARTITION_RAW_ENUM_FIELD_ID" } }, "value": "PartitionId2", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } true)
✅ ListPartitionsContainsShouldSucceed
✅ ListPartitionsEmptyResultShouldSucceed
✅ ReadPartitionAsyncShouldSucceed
✅ ReadTaskAsyncShouldThrowException

✅ ArmoniK.Core.Adapters.MongoDB.Tests.ResultTableTests

✅ AbortResultsShouldFail
✅ AbortResultsShouldSucceed
✅ AddDependentNotExistingResultShouldThrow
✅ AddDependentShouldSucceed
✅ ChangeResultOwnershipShouldSucceed
✅ CompleteResultShouldSucceed
✅ CompleteResultShouldThrow
✅ CreateShouldFail
✅ CreateShouldSucceed
✅ DeleteResultShouldRemoveOne
✅ DeleteResultsShouldRemoveAll
✅ DeleteUnknownResultShouldFail
✅ GetDependentsShouldSucceed
✅ GetDependentsShouldThrow
✅ GetEmptyDependentsShouldSucceed
✅ GetNotExistingResultStatusShouldSucceed
✅ GetResultBench
✅ GetResultsBench
✅ GetResultStatusShouldSucceed
✅ InitShouldSucceed
✅ ListResultsAsyncFilterResultStatusAndSessionIdLimit1ShouldSucceed
✅ ListResultsAsyncFilterResultStatusAndSessionIdShouldSucceed
✅ ListSessionAsyncNoFilterShouldSucceed
✅ ResultsAreAvailableShouldReturnAborted
✅ ResultsAreAvailableShouldReturnEmpty
✅ ResultsAreAvailableShouldSucceed
✅ SetResultShouldSucceed
✅ SetResultSmallPayloadShouldSucceed
✅ SetTaskOwnershipShouldFail
✅ SetTaskOwnershipShouldSucceed

✅ ArmoniK.Core.Adapters.MongoDB.Tests.ResultWatcherTests

✅ InitShouldSucceed
✅ WatchNewResultShouldSucceed
✅ WatchResultOwnerUpdateShouldSucceed
✅ WatchResultStatusUpdateShouldSucceed

✅ ArmoniK.Core.Adapters.MongoDB.Tests.SessionProviderTests

✅ SessionProviderGetBeforeInitShouldThrow
✅ SessionProviderInitShouldSucceed

✅ ArmoniK.Core.Adapters.MongoDB.Tests.SessionTableTests

✅ CancelCancelledSessionAsyncShouldFail
✅ CancelSessionAsyncShouldFail
✅ CancelSessionAsyncShouldSucceed
✅ DeleteSessionAsyncShouldFail
✅ DeleteSessionAsyncShouldSucceed
✅ GetDefaultTaskOptionAsyncShouldFail
✅ GetDefaultTaskOptionAsyncShouldSucceed
✅ InitShouldSucceed
✅ IsSessionCancelledAsyncShouldFail
✅ IsSessionCancelledAsyncShouldSucceed
✅ ListSessionAsyncFilterApplicationNameAndSessionIdShouldSucceed
✅ ListSessionAsyncFilterApplicationNameAndStatusShouldSucceed
✅ ListSessionAsyncFilterApplicationNameShouldSucceed
✅ ListSessionAsyncNoFilterShouldSucceed
✅ ListSessionAsyncShouldFail
✅ ListSessionAsyncShouldSucceed
✅ ListSessionAsyncShouldSucceed2
✅ ListSessionAsyncTaskOptionsOptions

✅ ArmoniK.Core.Adapters.MongoDB.Tests.TaskTableTests

✅ AcquireAcquiredTaskShouldReturnSame
✅ AcquireCreatingTaskShouldFail
✅ AcquireTaskShouldFail
✅ AcquireTaskShouldSucceed
✅ CancelSessionAsyncShouldSucceed
✅ CancelTasksAsyncEmptyListShouldSucceed
✅ CancelTasksAsyncShouldNotChangeTheGivenStatus(Cancelled)
✅ CancelTasksAsyncShouldNotChangeTheGivenStatus(Cancelling)
✅ CancelTasksAsyncShouldNotChangeTheGivenStatus(Completed)
✅ CancelTasksAsyncShouldNotChangeTheGivenStatus(Error)
✅ CancelTasksShouldSucceed
✅ CountAllTasksAsyncShouldSucceed
✅ CountPartitionTasksAsyncShouldSucceed
✅ CountTasksAsyncShouldSucceed
✅ DeleteTaskShouldFail
✅ DeleteTaskShouldSucceed
✅ FinalizeTaskCreationShouldFail
✅ FinalizeTaskCreationShouldSucceed
✅ FindTasksAsyncContainsShouldSucceed
✅ FindTasksAsyncStatusShouldSucceed(Completed,1)
✅ FindTasksAsyncStatusShouldSucceed(Processing,2)
✅ GetExpectedOutputKeysShouldSucceed
✅ GetParentTaskIdsShouldFail
✅ GetParentTaskIdsShouldSucceed
✅ GetTaskExpectedOutputKeysShouldFail
✅ GetTaskExpectedOutputKeysShouldSucceed
✅ GetTaskOutputShouldFail
✅ GetTaskOutputShouldSucceed
✅ InitShouldSucceed
✅ IsTaskCanceledShouldFail
✅ IsTaskCanceledShouldSucceed
✅ ListApplicationFromTasksShouldSucceed
✅ ListApplicationFromTasksSortShouldSucceed
✅ ListTaskEmptyResultShouldSucceed
✅ ListTaskFilter({ "number": { "field": { "taskOptionField": { "field": "TASK_OPTION_ENUM_FIELD_MAX_RETRIES" } }, "value": "5", "operator": "FILTER_NUMBER_OPERATOR_LESS_THAN_OR_EQUAL" } } true)
✅ ListTaskFilter({ "number": { "field": { "taskOptionField": { "field": "TASK_OPTION_ENUM_FIELD_MAX_RETRIES" } }, "value": "5", "operator": "FILTER_NUMBER_OPERATOR_LESS_THAN" } } false)
✅ ListTaskFilter({ "status": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_STATUS" } }, "value": "TASK_STATUS_CANCELLING", "operator": "FILTER_STATUS_OPERATOR_EQUAL" } } false)
✅ ListTaskFilter({ "status": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_STATUS" } }, "value": "TASK_STATUS_CANCELLING", "operator": "FILTER_STATUS_OPERATOR_NOT_EQUAL" } } true)
✅ ListTaskFilter({ "status": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_STATUS" } }, "value": "TASK_STATUS_COMPLETED", "operator": "FILTER_STATUS_OPERATOR_EQUAL" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskOptionField": { "field": "TASK_OPTION_ENUM_FIELD_PARTITION_ID" } }, "value": "BadPartitionId", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } false)
✅ ListTaskFilter({ "string": { "field": { "taskOptionField": { "field": "TASK_OPTION_ENUM_FIELD_PARTITION_ID" } }, "value": "part1", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskOptionGenericField": { "field": "key1" } }, "value": "val1", "operator": "FILTER_STRING_OPERATOR_CONTAINS" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskOptionGenericField": { "field": "key1" } }, "value": "val1", "operator": "FILTER_STRING_OPERATOR_ENDS_WITH" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskOptionGenericField": { "field": "key1" } }, "value": "val1", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskOptionGenericField": { "field": "key1" } }, "value": "val1", "operator": "FILTER_STRING_OPERATOR_STARTS_WITH" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "BadSessionId", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } false)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "BadSessionId", "operator": "FILTER_STRING_OPERATOR_NOT_CONTAINS" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "SessionId", "operator": "FILTER_STRING_OPERATOR_CONTAINS" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "SessionId", "operator": "FILTER_STRING_OPERATOR_ENDS_WITH" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "SessionId", "operator": "FILTER_STRING_OPERATOR_EQUAL" } } true)
✅ ListTaskFilter({ "string": { "field": { "taskSummaryField": { "field": "TASK_SUMMARY_ENUM_FIELD_SESSION_ID" } }, "value": "SessionId", "operator": "FILTER_STRING_OPERATOR_STARTS_WITH" } } true)
✅ ListTaskFilter(Date TaskSummaryField CreatedAt false)
✅ ListTaskFilter(Date TaskSummaryField CreatedAt false)
✅ ListTaskFilter(Date TaskSummaryField CreatedAt true)
✅ ListTaskFilter(Date TaskSummaryField CreatedAt true)
✅ ListTaskFilter(Date TaskSummaryField StartedAt true)
✅ ListTaskFilter(Date TaskSummaryField StartedAt true)
✅ ListTaskShouldSucceed
✅ ListTaskWithListInRequestShouldSucceed
✅ ListTaskWithRequestOrderByTaskOptionsOptionsShouldSucceed
✅ ListTaskWithRequestShouldSucceed
✅ OptionsAreEqual
✅ PayloadIdAfterRetryShouldBeCorrect
✅ ReadTaskAsyncShouldFail
✅ ReadTaskAsyncShouldSucceed
✅ ReleaseTaskShouldSucceed
✅ RemoveRemainingDataDependenciesDepDoesNotExistShouldSucceed
✅ RemoveRemainingDataDependenciesShouldSucceed
✅ RetryTaskShouldSucceed
✅ SetTaskCanceledAsyncShouldSucceed
✅ SetTaskErrorAsyncShouldSucceed
✅ SetTaskSuccessAsyncShouldSucceed
✅ StartTaskShouldFail
✅ StartTaskShouldSucceed
✅ UpdateAllTaskStatusAsyncShouldFailOnSomeStatus(Cancelled)
✅ UpdateAllTaskStatusAsyncShouldFailOnSomeStatus(Completed)
✅ UpdateAllTaskStatusAsyncShouldFailOnSomeStatus(Error)
✅ UpdateAllTaskStatusAsyncShouldSucceed
✅ UpdateAllTaskStatusAsyncShouldSucceedIfNoStatusGiven

✅ ArmoniK.Core.Adapters.MongoDB.Tests.TaskWatcherTests

✅ InitShouldSucceed
✅ WatchNewResultShouldSucceed
✅ WatchResultStatusUpdateShouldSucceed