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

docs: no hashing of topics in the test layers #188

Merged
merged 2 commits into from
Apr 6, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 6 additions & 17 deletions packages/integration-test/test/layers.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,7 @@ describe('Request system', () => {
payer,
};

const topics = [
Utils.crypto.normalizeKeccak256Hash(payeeIdentity),
Utils.crypto.normalizeKeccak256Hash(payer),
];
const topics = [payeeIdentity, payer];

const resultCreation = await requestLogic.createRequest(
requestCreationHash,
Expand Down Expand Up @@ -223,10 +220,7 @@ describe('Request system', () => {
payer,
};

const topics = [
Utils.crypto.normalizeKeccak256Hash(payeeIdentity),
Utils.crypto.normalizeKeccak256Hash(payer),
];
const topics = [payeeIdentity, payer];

const resultCreation = await requestLogic.createRequest(
requestCreationHash,
Expand Down Expand Up @@ -275,6 +269,7 @@ describe('Request system', () => {

const requestCreationHash: RequestLogicTypes.ICreateParameters = {
currency: {
network: 'testnet',
type: RequestLogicTypes.CURRENCY.BTC,
value: 'BTC',
},
Expand All @@ -284,10 +279,7 @@ describe('Request system', () => {
payer,
};

const topics = [
Utils.crypto.normalizeKeccak256Hash(payeeIdentity),
Utils.crypto.normalizeKeccak256Hash(payer),
];
const topics = [payeeIdentity, payer];

const resultCreation = await requestLogic.createRequest(
requestCreationHash,
Expand Down Expand Up @@ -322,7 +314,7 @@ describe('Request system', () => {
timestamp: Utils.getCurrentTimestampInSecond(),
};
// create a unique topic just to not have collisions in tests
const topics1 = [Utils.crypto.normalizeKeccak256Hash(request1CreationHash)];
const topics1 = [request1CreationHash];
const resultCreation1 = await requestLogic.createRequest(
request1CreationHash,
payeeIdentity,
Expand Down Expand Up @@ -411,10 +403,7 @@ describe('Request system', () => {
payer: payerIdentity,
};

const topics = [
Utils.crypto.normalizeKeccak256Hash(payeeIdentity),
Utils.crypto.normalizeKeccak256Hash(payerIdentity),
];
const topics = [payeeIdentity, payerIdentity];

const resultCreation = await requestLogic.createEncryptedRequest(
requestCreationHash,
Expand Down