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

fix: remove id from item market and bazaar #761

Merged
merged 1 commit into from
May 17, 2024
Merged
Show file tree
Hide file tree
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
1 change: 0 additions & 1 deletion lib/Interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1458,7 +1458,6 @@ export interface IUserSkill {
}

export interface IMarketItem {
ID: number;
cost: number;
quantity: number;
}
Expand Down
22 changes: 11 additions & 11 deletions test/ItemMarket.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ describe('ItemMarket API', () => {
const castedReturn = initialReturn as IMarketItem[];

// spot check one
const item = castedReturn.find((x) => x.ID === 46596312);
expect(item?.cost).to.equal(950);
expect(item?.quantity).to.equal(7);
const item = castedReturn[0];
expect(item?.cost).to.equal(919);
expect(item?.quantity).to.equal(11);
});

it('itemmarket', async () => {
Expand All @@ -39,8 +39,8 @@ describe('ItemMarket API', () => {
const castedReturn = initialReturn as IMarketItem[];

// spot check one
const item = castedReturn.find((x) => x.ID === 131761544);
expect(item?.cost).to.equal(320);
const item = castedReturn[0];
expect(item?.cost).to.equal(250);
expect(item?.quantity).to.equal(1);
});

Expand Down Expand Up @@ -71,12 +71,12 @@ describe('ItemMarket API', () => {
const castedReturn = initialReturn as IMarketItem[];

// spot check one from each
let item = castedReturn.find((x) => x.ID === 131761544);
expect(item?.cost).to.equal(320);
expect(item?.quantity).to.equal(1);
let item = castedReturn[0];
expect(item?.cost).to.equal(265);
expect(item?.quantity).to.equal(12);

item = castedReturn.find((x) => x.ID === 11616293);
expect(item?.cost).to.equal(750);
expect(item?.quantity).to.equal(10);
item = castedReturn[1];
expect(item?.cost).to.equal(290);
expect(item?.quantity).to.equal(11);
});
});
Loading
Loading