Skip to content

Commit

Permalink
fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
DaevMithran committed Sep 9, 2024
1 parent 9450d4d commit e23643a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions tests/unit/diddoc/common/did_doc_resolve_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ var _ = DescribeTable("Test Resolve method", func(testCase resolveDidDocTestCase
testCase.expectedDIDResolution.Did.Context = []string{
types.DIDSchemaJSONLD,
types.JsonWebKey2020JSONLD,
types.DIFDIDConfigurationJSONLD
}
} else if testCase.expectedDIDResolution.Did != nil {
testCase.expectedDIDResolution.Did.Context = nil
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/diddoc/request/diddoc_positive_cases_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ var _ = DescribeTable("Test Query handlers with versionId and versionTime params
expectedDIDResolution := testCase.expectedResolution.(*types.DidResolution)

if (testCase.resolutionType == "" || testCase.resolutionType == types.DIDJSONLD) && testCase.expectedError == nil {
expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.JsonWebKey2020JSONLD}
expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.DIFDIDConfigurationJSONLD, types.JsonWebKey2020JSONLD }
} else if expectedDIDResolution.Did != nil {
expectedDIDResolution.Did.Context = nil
}
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/diddoc/request/diddoc_transform_key_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ var _ = DescribeTable("Test Query handler with transformKeys params", func(testC
expectedDIDResolution := testCase.expectedResolution.(*types.DidResolution)

if (testCase.resolutionType == "" || testCase.resolutionType == types.DIDJSONLD) && testCase.expectedError == nil {
expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.JsonWebKey2020JSONLD}
expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.DIFDIDConfigurationJSONLD, types.JsonWebKey2020JSONLD }
} else if expectedDIDResolution.Did != nil {
expectedDIDResolution.Did.Context = nil
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ var _ = DescribeTable("Test DIDDocEchoHandler function", func(testCase resolveDI
context, rec := utils.SetupEmptyContext(request, testCase.resolutionType, utils.MockLedger)

if (testCase.resolutionType == "" || testCase.resolutionType == types.DIDJSONLD) && testCase.expectedError == nil {
testCase.expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.JsonWebKey2020JSONLD}
testCase.expectedDIDResolution.Did.Context = []string{types.DIDSchemaJSONLD, types.DIFDIDConfigurationJSONLD, types.JsonWebKey2020JSONLD }
} else if testCase.expectedDIDResolution.Did != nil {
testCase.expectedDIDResolution.Did.Context = nil
}
Expand Down

0 comments on commit e23643a

Please sign in to comment.