Skip to content

Commit

Permalink
fix: merged main
Browse files Browse the repository at this point in the history
  • Loading branch information
akp111 committed Nov 28, 2023
2 parents 175e390 + 73f3e9c commit aebe533
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 52 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -678,7 +678,7 @@ export class PushNotificationBaseClass {
return 0;
}

public getMinimalSetting(configuration: NotificationSettings): {
protected getMinimalSetting(configuration: NotificationSettings): {
setting: string;
description: string;
} {
Expand Down
88 changes: 37 additions & 51 deletions packages/restapi/tests/lib/pushNotification/base.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,57 +125,43 @@ describe.only('test', () => {
// );
// console.log(approveRes2);
// });
it('Should get proper minnimal payload', async() => {
const inputData = [
{
type: 1,
default: 1,
description: 'test1',
},
{
type: 2,
default: 10,
description: 'test2',
data: {
upper: 100,
lower: 1,
},
},
{
type: 3,
default: {
lower: 10,
upper: 50
},
description: 'test3',
data: {
upper: 100,
lower: 1,
enabled:true,
ticker:2
}
},
{
type: 3,
default: {
lower: 3,
upper: 5
},
description: 'test4',
data: {
upper: 100,
lower: 1,
enabled:false,
ticker:2
}
}
];
const account2 = await signer2.getAddress();
const userAlice = new PushNotificationBaseClass(signer2, ENV.STAGING, account2,);
const minimalSettings = userAlice.getMinimalSetting(inputData);
console.log(minimalSettings);
expect(minimalSettings).not.null
});
// it('Should get proper minnimal payload', async() => {
// const inputData = [
// {
// type: 1,
// default: 1,
// description: 'test1',
// },
// {
// type: 2,
// default: 10,
// description: 'test2',
// data: {
// upper: 100,
// lower: 1,
// },
// },
// {
// type: 3,
// default: {
// lower: 10,
// upper: 50
// },
// description: 'test3',
// data: {
// upper: 100,
// lower: 1,
// enabled:true,
// ticker:2
// }
// }
// ];
// const account2 = await signer2.getAddress();
// const userAlice = new PushNotificationBaseClass(signer2, ENV.STAGING, account2,);
// const minimalSettings = userAlice.getMinimalSetting(inputData);
// // console.log(minimalSettings);
// expect(minimalSettings).not.null
// });

// it('Should get proper minnimal payload', async() => {
// const inputData = [
Expand Down

0 comments on commit aebe533

Please sign in to comment.