Skip to content

Commit 490b8a4

Browse files
committed
update tests and CI
1 parent f60c310 commit 490b8a4

File tree

3 files changed

+65
-23
lines changed

3 files changed

+65
-23
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77

88
strategy:
99
matrix:
10-
node: ["12", "16"]
10+
node: ["18", "22"]
1111
fail-fast: false
1212

1313
steps:
@@ -23,7 +23,7 @@ jobs:
2323
run: "npm ci"
2424

2525
- name: "Lint Code"
26-
if: ${{ matrix.node == '16' }}
26+
if: ${{ matrix.node == '18' }}
2727
run: "npx eslint -f .github/workflows/formatter.js src/**/*.ts || :"
2828

2929
- name: "Compile Code"

.github/workflows/web.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set Up NodeJS
1717
uses: actions/setup-node@v2
1818
with:
19-
node-version: 16
19+
node-version: 22
2020

2121
- name: Checkout Master Branch
2222
uses: actions/checkout@v2

tests/client.test.js

Lines changed: 62 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -54,36 +54,85 @@ describe('Client Methods (Without API Key)', () => {
5454
expect(response.data).toBeDefined();
5555
});
5656

57-
it('Runs Client#cosmeticsList()', async () => {
58-
const response = await client.cosmeticsList();
57+
it('Runs Client#allCosmetics()', async () => {
58+
const response = await client.allCosmetics();
5959

6060
expect(response.status).toBe(200);
6161
expect(response.data).toBeDefined();
6262
});
6363

64-
it('Runs Client#cosmeticsByID()', async () => {
65-
const response = await client.cosmeticsByID({ id: 'CID_022_Athena_Commando_F' });
64+
it('Runs Client#brCosmeticsList()', async () => {
65+
const response = await client.brCosmeticsList();
6666

6767
expect(response.status).toBe(200);
6868
expect(response.data).toBeDefined();
6969
});
7070

71-
it('Runs Client#cosmeticsSearch()', async () => {
72-
const response = await client.cosmeticsSearch({ name: 'Recon', matchMethod: 'starts' });
71+
it('Runs Client#trackCosmeticsList()', async () => {
72+
const response = await client.trackCosmeticsList();
7373

7474
expect(response.status).toBe(200);
7575
expect(response.data).toBeDefined();
7676
});
7777

78-
it('Runs Client#cosmeticsSearchAll()', async () => {
79-
const response = await client.cosmeticsSearchAll({ name: 'Recon', matchMethod: 'starts' });
78+
it('Runs Client#instrumentCosmeticsList()', async () => {
79+
const response = await client.instrumentCosmeticsList();
8080

8181
expect(response.status).toBe(200);
8282
expect(response.data).toBeDefined();
8383
});
8484

85-
it('Runs Client#cosmeticsSearchByIDs()', async () => {
86-
const response = await client.cosmeticsSearchByIDs({ id: ['CID_022_Athena_Commando_F', 'CID_242_Athena_Commando_F_Bullseye'] });
85+
it('Runs Client#carCosmeticsList()', async () => {
86+
const response = await client.carCosmeticsList();
87+
88+
expect(response.status).toBe(200);
89+
expect(response.data).toBeDefined();
90+
});
91+
92+
it('Runs Client#legoCosmeticsList()', async () => {
93+
const response = await client.legoCosmeticsList();
94+
95+
expect(response.status).toBe(200);
96+
expect(response.data).toBeDefined();
97+
});
98+
99+
it('Runs Client#legoKitCosmeticsList()', async () => {
100+
const response = await client.legoKitCosmeticsList();
101+
102+
expect(response.status).toBe(200);
103+
expect(response.data).toBeDefined();
104+
});
105+
106+
it('Runs Client#beanCosmeticsList()', async () => {
107+
const response = await client.beanCosmeticsList();
108+
109+
expect(response.status).toBe(200);
110+
expect(response.data).toBeDefined();
111+
});
112+
113+
it('Runs Client#brCosmeticByID()', async () => {
114+
const response = await client.brCosmeticByID('CID_022_Athena_Commando_F');
115+
116+
expect(response.status).toBe(200);
117+
expect(response.data).toBeDefined();
118+
});
119+
120+
it('Runs Client#brCosmeticSearch()', async () => {
121+
const response = await client.brCosmeticSearch({ name: 'Recon', matchMethod: 'starts' });
122+
123+
expect(response.status).toBe(200);
124+
expect(response.data).toBeDefined();
125+
});
126+
127+
it('Runs Client#brCosmeticsSearch()', async () => {
128+
const response = await client.brCosmeticsSearch({ name: 'Recon', matchMethod: 'starts' });
129+
130+
expect(response.status).toBe(200);
131+
expect(response.data).toBeDefined();
132+
});
133+
134+
it('Runs Client#brCosmeticsSearchByIDs()', async () => {
135+
const response = await client.brCosmeticsSearchByIDs({ id: ['CID_022_Athena_Commando_F', 'CID_242_Athena_Commando_F_Bullseye'] });
87136

88137
expect(response.status).toBe(200);
89138
expect(response.data).toBeDefined();
@@ -118,21 +167,14 @@ describe('Client Methods (Without API Key)', () => {
118167
});
119168

120169
it('Runs Client#playlistById()', async () => {
121-
const response = await client.playlistById({ id: 'Playlist_DefaultSolo' });
122-
123-
expect(response.status).toBe(200);
124-
expect(response.data).toBeDefined();
125-
});
126-
127-
it('Runs Client#brShop()', async () => {
128-
const response = await client.brShop();
170+
const response = await client.playlistByID('Playlist_DefaultSolo');
129171

130172
expect(response.status).toBe(200);
131173
expect(response.data).toBeDefined();
132174
});
133175

134-
it('Runs Client#brShopCombined()', async () => {
135-
const response = await client.brShopCombined();
176+
it('Runs Client#shop()', async () => {
177+
const response = await client.shop();
136178

137179
expect(response.status).toBe(200);
138180
expect(response.data).toBeDefined();

0 commit comments

Comments
 (0)