Skip to content
Snippets Groups Projects

feat(ssi): schema functionality

Merged Berend Sliedrecht requested to merge tsabolov/ocm-engine:schemas into main
13 files
+ 328
22
Compare changes
  • Side-by-side
  • Inline
Files
13
@@ -5,6 +5,7 @@ import {
@@ -5,6 +5,7 @@ import {
} from '@aries-framework/core';
} from '@aries-framework/core';
import {
import {
 
EventDidcommConnectionsBlock,
EventDidcommConnectionsCreateWithSelf,
EventDidcommConnectionsCreateWithSelf,
EventDidcommConnectionsGetAll,
EventDidcommConnectionsGetAll,
EventDidcommConnectionsGetById,
EventDidcommConnectionsGetById,
@@ -49,4 +50,21 @@ describe('Connection Events', () => {
@@ -49,4 +50,21 @@ describe('Connection Events', () => {
state: DidExchangeState.Completed,
state: DidExchangeState.Completed,
});
});
});
});
 
 
it('should create a new connections block event', () => {
 
const event = new EventDidcommConnectionsBlock(
 
new ConnectionRecord({
 
role: DidExchangeRole.Requester,
 
state: DidExchangeState.Completed,
 
}),
 
);
 
 
expect(typeof event.id).toStrictEqual('string');
 
expect(event.type).toStrictEqual('EventDidcommConnectionsBlock');
 
expect(event.timestamp).toBeInstanceOf(Date);
 
expect(event.instance).toMatchObject({
 
role: DidExchangeRole.Requester,
 
state: DidExchangeState.Completed,
 
});
 
});
});
});
Loading