gatsby-core-theme 44.17.0 → 44.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/package.json +1 -1
- package/src/constants/settings.mjs +5 -5
- package/src/resolver/index.mjs +14 -0
- package/src/resolver/modules.test.js +18 -11
- package/src/resolver/operators.mjs +6 -0
- package/src/resolver/operators.test.js +42 -292
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,30 @@
|
|
|
1
|
+
# [44.18.0](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.17.1...v44.18.0) (2026-03-10)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* fix tests ([aaece89](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/aaece89970dc76b200205ff3b0dca8aee935b527))
|
|
7
|
+
* update resolver to include different toplist for sportsbook ([2723466](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/2723466451dc9770297a392806ccae4d4f969e2d))
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
* Merge branch 'en-396-alternate-toplist' into 'master' ([9a08302](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/9a0830248359050d88cb5d8e625a5bb196380ec7))
|
|
11
|
+
* Merge branch 'bonus-ribbons' into 'master' ([e0c9a3b](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/e0c9a3bfdab5431dec873270f12f2330ddcc6eb7))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Features
|
|
15
|
+
|
|
16
|
+
* bonus ribbons ([aea19ae](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/aea19aefc3496c51efcbf96261fa0efa47634b78))
|
|
17
|
+
|
|
18
|
+
## [44.17.1](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.17.0...v44.17.1) (2026-03-09)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Bug Fixes
|
|
22
|
+
|
|
23
|
+
* filter out not recomended casinos ([49197fb](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/49197fb6a6a07de328a3cce594248dba2e5595d3))
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
* Merge branch 'EN-399' into 'master' ([e8022d0](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/commit/e8022d0e5e295045b59c17c1eb33a63b20494db8))
|
|
27
|
+
|
|
1
28
|
# [44.17.0](https://gitlab.com/g2m-gentoo/team-floyd/themes/gatsby-themes/compare/v44.16.3...v44.17.0) (2026-03-06)
|
|
2
29
|
|
|
3
30
|
|
package/package.json
CHANGED
|
@@ -8,14 +8,14 @@ export default {
|
|
|
8
8
|
'default' : ['cards', 'cards_v2']
|
|
9
9
|
},
|
|
10
10
|
filter_cards_modules: {
|
|
11
|
-
'irishluck.ie': ['inactive', 'blacklisted', 'coming_soon'],
|
|
12
|
-
'norskespilleautomater.com': ['inactive', 'blacklisted', 'coming_soon'],
|
|
13
|
-
'playcasino.co.za': ['inactive', 'blacklisted', 'coming_soon'],
|
|
14
|
-
'onlinegamblingsa.co.za': ['inactive', 'blacklisted', 'coming_soon'],
|
|
11
|
+
'irishluck.ie': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
12
|
+
'norskespilleautomater.com': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
13
|
+
'playcasino.co.za': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
14
|
+
'onlinegamblingsa.co.za': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
15
15
|
'onlinegamblingsa.com': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
16
16
|
'onlinecasinosouthafrica.net': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
17
17
|
'free-casinos.co.za': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended'],
|
|
18
|
-
'default': ['inactive', 'blacklisted']
|
|
18
|
+
'default': ['inactive', 'blacklisted', 'coming_soon', 'not_recommended']
|
|
19
19
|
},
|
|
20
20
|
keep_page_extra_fields: {
|
|
21
21
|
operator: {
|
package/src/resolver/index.mjs
CHANGED
|
@@ -634,6 +634,20 @@ export default {
|
|
|
634
634
|
)
|
|
635
635
|
)
|
|
636
636
|
return;
|
|
637
|
+
|
|
638
|
+
if (item.name === "top_list") {
|
|
639
|
+
const shortCode = item?.items?.[0]?.value;
|
|
640
|
+
const isSportsbook =
|
|
641
|
+
page?.relation?.type === "sportsbook";
|
|
642
|
+
|
|
643
|
+
const shouldSkip =
|
|
644
|
+
(isSportsbook &&
|
|
645
|
+
shortCode === "inactive_operator_toplist") ||
|
|
646
|
+
(!isSportsbook &&
|
|
647
|
+
shortCode === "inactive_sportsbook_toplist");
|
|
648
|
+
|
|
649
|
+
if (shouldSkip) return;
|
|
650
|
+
}
|
|
637
651
|
|
|
638
652
|
res === "pre_main_operators"
|
|
639
653
|
? page.sections.main.modules.unshift(cloneDeep(item))
|
|
@@ -221,17 +221,24 @@ describe("Modules Helper", () => {
|
|
|
221
221
|
});
|
|
222
222
|
|
|
223
223
|
test("Process Bonus function", () => {
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
224
|
+
const module = { value: 1 };
|
|
225
|
+
|
|
226
|
+
const relations = {
|
|
227
|
+
operator: {
|
|
228
|
+
1: {
|
|
229
|
+
test: "test",
|
|
230
|
+
ribbons: [2],
|
|
231
|
+
bonuses: {},
|
|
232
|
+
logo: { filename: "test.jpg" },
|
|
233
|
+
},
|
|
234
|
+
},
|
|
235
|
+
ribbons: { 2: { label: "testRibbon" } },
|
|
236
|
+
};
|
|
237
|
+
|
|
238
|
+
processBonus(module, relations);
|
|
239
|
+
|
|
240
|
+
expect(module.value.ribbons).toHaveLength(1);
|
|
241
|
+
expect(module.value.ribbons[0]).toBe("testRibbon");
|
|
235
242
|
});
|
|
236
243
|
|
|
237
244
|
test("Process TopList module", () => {
|
|
@@ -42,6 +42,12 @@ export function sanitizeOperatorData(
|
|
|
42
42
|
}
|
|
43
43
|
});
|
|
44
44
|
|
|
45
|
+
//Set ribbons per bonus type
|
|
46
|
+
Object.entries(operatorClone.bonuses).forEach((item) =>{
|
|
47
|
+
operatorClone.bonuses[item[0]].ribbons = operator?.bonuses[item[0]]?.ribbon_ids?.map(res =>{
|
|
48
|
+
return data.ribbons[res]?.label})
|
|
49
|
+
})
|
|
50
|
+
|
|
45
51
|
// filter out null ribbons
|
|
46
52
|
operatorClone.ribbons = ribbons.filter((n) => n);
|
|
47
53
|
}
|
|
@@ -1,305 +1,55 @@
|
|
|
1
|
-
import { cleanup
|
|
1
|
+
import { cleanup } from "@testing-library/react";
|
|
2
2
|
import { sanitizeOperatorData } from "./operators.mjs";
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
getRelationsData,
|
|
5
|
+
getTransformedV2operator,
|
|
6
|
+
} from "../../tests/factories/relations/operatorV2.factory";
|
|
4
7
|
import getPageDataList from "../../tests/factories/pages/list.factory";
|
|
5
8
|
|
|
6
9
|
describe("Sanitize Operator Data", () => {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
+
test("Sanitize Data with Operator Page", () => {
|
|
11
|
+
const operatorData = getTransformedV2operator();
|
|
12
|
+
operatorData.bonuses = {};
|
|
13
|
+
const operatorPage = getPageDataList(1);
|
|
14
|
+
|
|
15
|
+
const sanitizedOperator = sanitizeOperatorData(
|
|
16
|
+
operatorData,
|
|
17
|
+
operatorPage,
|
|
18
|
+
getRelationsData()
|
|
19
|
+
);
|
|
20
|
+
|
|
21
|
+
expect(sanitizedOperator.author_image).toBe("author_logo.webp");
|
|
22
|
+
expect(sanitizedOperator.author_name).toBe("author name");
|
|
23
|
+
expect(sanitizedOperator.author_path).toBe("/author/link");
|
|
24
|
+
expect(sanitizedOperator.email).toBe("risk@support.com");
|
|
25
|
+
expect(sanitizedOperator.deposit_methods).toHaveLength(2);
|
|
26
|
+
expect(sanitizedOperator.ribbons).toHaveLength(1);
|
|
27
|
+
expect(sanitizedOperator.ribbons[0]).toBe("testRibbon");
|
|
28
|
+
expect(sanitizedOperator.review_link).toBe("sport/brand");
|
|
10
29
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
expect(sanitizedOperator.author_image).toBe('author_logo.webp');
|
|
14
|
-
expect(sanitizedOperator.author_name).toBe('author name');
|
|
15
|
-
expect(sanitizedOperator.author_path).toBe('/author/link');
|
|
16
|
-
expect(sanitizedOperator.email).toBe('risk@support.com');
|
|
17
|
-
expect(sanitizedOperator.deposit_methods).toHaveLength(2);
|
|
18
|
-
expect(sanitizedOperator.ribbons).toHaveLength(1);
|
|
19
|
-
expect(sanitizedOperator.ribbons[0]).toBe('testRibbon');
|
|
20
|
-
expect(sanitizedOperator.review_link).toBe('sport/brand');
|
|
21
|
-
});
|
|
22
|
-
test("Handles missing optional fields gracefully", () => {
|
|
23
|
-
const operatorData = {
|
|
24
|
-
name: "Test Casino",
|
|
25
|
-
ribbons: [null, "customLabel", 2],
|
|
26
|
-
operator_url: "/test-url",
|
|
27
|
-
};
|
|
28
|
-
const operatorPage = [{}];
|
|
29
|
-
const relations = { ribbons: { 2: { label: "fromRelations" } } };
|
|
30
|
-
|
|
31
|
-
const result = sanitizeOperatorData(operatorData, operatorPage, relations);
|
|
32
|
-
|
|
33
|
-
expect(result.name).toBe("Test Casino");
|
|
34
|
-
expect(result.url).toBe("/test-url");
|
|
35
|
-
expect(result.ribbons).toEqual(["customLabel", "fromRelations"]);
|
|
36
|
-
expect(result.author_name).toBeUndefined();
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
// test("Sanitize Data with Transformed Pages Object", () => {
|
|
41
|
-
// const operatorsData = {
|
|
42
|
-
// yyy: {
|
|
43
|
-
// id: 1501,
|
|
44
|
-
// general_data: {
|
|
45
|
-
// id: 1501,
|
|
46
|
-
// name: "YYY Casino",
|
|
47
|
-
// short_name: "yyy",
|
|
48
|
-
// min_deposit: "10",
|
|
49
|
-
// min_withdrawal: "10",
|
|
50
|
-
// max_withdrawal: "5000",
|
|
51
|
-
// games_amount: "500+",
|
|
52
|
-
// },
|
|
53
|
-
// markets_data: {
|
|
54
|
-
// arab_en: {
|
|
55
|
-
// casino: {
|
|
56
|
-
// min_deposit: "20",
|
|
57
|
-
// min_withdrawal: "20",
|
|
58
|
-
// max_withdrawal: "10000",
|
|
59
|
-
// games_amount: "1000+",
|
|
60
|
-
// currency_ids: [152],
|
|
61
|
-
// deposit_method_ids: [1,2,],
|
|
62
|
-
// rating: "4.6",
|
|
63
|
-
// rating_casino: "5",
|
|
64
|
-
// rating_games: "4",
|
|
65
|
-
// rating_bonuses: "4",
|
|
66
|
-
// rating_customer: "5",
|
|
67
|
-
// rating_payout: "5",
|
|
68
|
-
// },
|
|
69
|
-
// },
|
|
70
|
-
// },
|
|
71
|
-
// sites_data: {
|
|
72
|
-
// arab_en: {
|
|
73
|
-
// casino: {
|
|
74
|
-
// id: 29788,
|
|
75
|
-
// market_id: 86,
|
|
76
|
-
// market: "arab_en",
|
|
77
|
-
// rating_casino: null,
|
|
78
|
-
// rating_games: "10",
|
|
79
|
-
// rating_bonuses: null,
|
|
80
|
-
// rating_customer: null,
|
|
81
|
-
// rating_payout: null,
|
|
82
|
-
// rating: "8",
|
|
83
|
-
// currency_ids: [2,3,4],
|
|
84
|
-
// country_ids: [62,23,],
|
|
85
|
-
// min_deposit: "22",
|
|
86
|
-
// min_withdrawal: "30",
|
|
87
|
-
// max_withdrawal: "20000",
|
|
88
|
-
// games_amount: "1500+",
|
|
89
|
-
// payout_time: "1-3 days",
|
|
90
|
-
// },
|
|
91
|
-
// },
|
|
92
|
-
// arab_ar: {
|
|
93
|
-
// casino: {
|
|
94
|
-
// id: 29798,
|
|
95
|
-
// market_id: 144,
|
|
96
|
-
// market: "arab_ar",
|
|
97
|
-
// rating_casino: null,
|
|
98
|
-
// rating_games: "10",
|
|
99
|
-
// rating_bonuses: null,
|
|
100
|
-
// rating_customer: null,
|
|
101
|
-
// rating_payout: null,
|
|
102
|
-
// rating: "8",
|
|
103
|
-
// currency_ids: [2,3,4],
|
|
104
|
-
// restricted_country_ids: [253],
|
|
105
|
-
// min_deposit: "22",
|
|
106
|
-
// min_withdrawal: "30",
|
|
107
|
-
// max_withdrawal: "20000",
|
|
108
|
-
// games_amount: "1500+",
|
|
109
|
-
// payout_time: "1-3 days",
|
|
110
|
-
// },
|
|
111
|
-
// },
|
|
112
|
-
// },
|
|
113
|
-
// },
|
|
114
|
-
// };
|
|
115
|
-
|
|
116
|
-
// const transformed = transformOperators(operatorsData, {payments: {}, currencies: {}});
|
|
117
|
-
|
|
118
|
-
// expect(transformed[29788].rating_games).toBe('10');
|
|
119
|
-
// expect(transformed[29788].rating_casino).toBe('5');
|
|
120
|
-
// expect(transformed[29788].rating).toBe('8');
|
|
121
|
-
// expect(transformed[29788].max_withdrawal).toBe('20000');
|
|
122
|
-
// expect(transformed[29788].currency_ids).toHaveLength(3);
|
|
123
|
-
// });
|
|
124
|
-
|
|
125
|
-
// test('Test transformOperators with operator Object', () => {
|
|
126
|
-
// const market2Affiliates = Object.values(Object.values(operator.yyy.sites_data)[1]);
|
|
127
|
-
|
|
128
|
-
// expect(Object.keys(transformedOperators).length).toBe(4);
|
|
129
|
-
// expect(Object.keys(transformedOperators).length).toBe(market1Affiliates.length + market2Affiliates.length);
|
|
130
|
-
// });
|
|
131
|
-
|
|
132
|
-
// test('Test transformOperators - final object is using the affiliate ID as a key', () => {
|
|
133
|
-
// const market2Affiliates = Object.values(Object.values(operator.yyy.sites_data)[1]);
|
|
134
|
-
|
|
135
|
-
// expect(Object.keys(transformedOperators)[0]).toBe("29788");
|
|
136
|
-
// expect(Object.keys(transformedOperators)).toContain(`${market1Affiliates[2].id}`);
|
|
137
|
-
// expect(Object.keys(transformedOperators)).toContain(`${market2Affiliates[0].id}`);
|
|
138
|
-
// });
|
|
139
|
-
|
|
140
|
-
// test('Test transformOperators - test that site data overrides markets data and general data', () => {
|
|
141
|
-
// // test general data exisits
|
|
142
|
-
// expect(generalData.min_deposit).toEqual('10');
|
|
143
|
-
// expect(generalData.min_withdrawal).toEqual('10');
|
|
144
|
-
// expect(generalData.max_withdrawal).toEqual('5000');
|
|
145
|
-
|
|
146
|
-
// // test market data exisits
|
|
147
|
-
// expect(marketData1[0].min_deposit).toEqual('20');
|
|
148
|
-
// expect(marketData1[0].min_withdrawal).toEqual('20');
|
|
149
|
-
// expect(marketData1[0].max_withdrawal).toEqual('10000');
|
|
150
|
-
|
|
151
|
-
// // test sites data exisits
|
|
152
|
-
// expect(market1Affiliates[0].min_deposit).toEqual('22');
|
|
153
|
-
// expect(market1Affiliates[0].min_withdrawal).toEqual('30');
|
|
154
|
-
// expect(market1Affiliates[0].max_withdrawal).toEqual('20000');
|
|
155
|
-
|
|
156
|
-
// // test that final data overrides sites data when available
|
|
157
|
-
// expect(Object.values(transformedOperators)[0].min_deposit).not.toEqual(generalData.min_deposit);
|
|
158
|
-
// expect(Object.values(transformedOperators)[0].min_deposit).not.toEqual(marketData1[0].min_deposit);
|
|
159
|
-
// expect(Object.values(transformedOperators)[0].min_deposit).toEqual(market1Affiliates[0].min_deposit);
|
|
160
|
-
|
|
161
|
-
// expect(Object.values(transformedOperators)[0].min_withdrawal).not.toEqual(generalData.min_withdrawal);
|
|
162
|
-
// expect(Object.values(transformedOperators)[0].min_withdrawal).not.toEqual(marketData1[0].min_withdrawal);
|
|
163
|
-
// expect(Object.values(transformedOperators)[0].min_withdrawal).toEqual(market1Affiliates[0].min_withdrawal);
|
|
164
|
-
|
|
165
|
-
// expect(Object.values(transformedOperators)[0].max_withdrawal).not.toEqual(generalData.max_withdrawal);
|
|
166
|
-
// expect(Object.values(transformedOperators)[0].max_withdrawal).not.toEqual(marketData1[0].max_withdrawal);
|
|
167
|
-
// expect(Object.values(transformedOperators)[0].max_withdrawal).toEqual(market1Affiliates[0].max_withdrawal);
|
|
168
|
-
// });
|
|
169
|
-
|
|
170
|
-
// test('Test transformOperators - test that when site data is empty markets data and general data overrides', () => {
|
|
171
|
-
// // test general data exisits
|
|
172
|
-
// expect(generalData.games_amount).toEqual('500+');
|
|
173
|
-
// expect(generalData.payout_time).toEqual('2-3 days');
|
|
174
|
-
|
|
175
|
-
// // test market data exisits
|
|
176
|
-
// expect(marketData1[0].games_amount).toEqual(null);
|
|
177
|
-
// expect(marketData1[0].payout_time).toEqual(null);
|
|
178
|
-
// expect(marketData1[0].rating_casino).toEqual('5');
|
|
179
|
-
// expect(marketData1[0].rating_games).toEqual('4');
|
|
180
|
-
|
|
181
|
-
// // test sites data does not exisits
|
|
182
|
-
// expect(market1Affiliates[0].rating_casino).toEqual(null);
|
|
183
|
-
// expect(market1Affiliates[0].rating_games).toEqual(null);
|
|
184
|
-
// expect(market1Affiliates[0].games_amount).toEqual(null);
|
|
185
|
-
// expect(market1Affiliates[0].payout_time).toEqual(null);
|
|
186
|
-
|
|
187
|
-
// // test that final data overrides sites data when available
|
|
188
|
-
// expect(Object.values(transformedOperators)[0].rating_casino).not.toEqual(market1Affiliates[0].rating_casino);
|
|
189
|
-
// expect(Object.values(transformedOperators)[0].rating_casino).toEqual(marketData1[0].rating_casino);
|
|
190
|
-
|
|
191
|
-
// expect(Object.values(transformedOperators)[0].rating_games).not.toEqual(market1Affiliates[0].rating_games);
|
|
192
|
-
// expect(Object.values(transformedOperators)[0].rating_games).toEqual(marketData1[0].rating_games);
|
|
193
|
-
|
|
194
|
-
// expect(Object.values(transformedOperators)[0].payout_time).not.toEqual(market1Affiliates[0].payout_time);
|
|
195
|
-
// expect(Object.values(transformedOperators)[0].payout_time).not.toEqual(marketData1[0].payout_time);
|
|
196
|
-
// expect(Object.values(transformedOperators)[0].payout_time).toEqual(generalData.payout_time);
|
|
197
|
-
|
|
198
|
-
// expect(Object.values(transformedOperators)[0].games_amount).not.toEqual(market1Affiliates[0].games_amount);
|
|
199
|
-
// expect(Object.values(transformedOperators)[0].payout_time).not.toEqual(marketData1[0].payout_time);
|
|
200
|
-
// expect(Object.values(transformedOperators)[0].games_amount).toEqual(generalData.games_amount);
|
|
201
|
-
// });
|
|
202
|
-
|
|
203
|
-
// test('Test transformOperators - test that when both site data and market data is empty general data overrides', () => {
|
|
204
|
-
// // // test general data exisits
|
|
205
|
-
// expect(generalData.rating).toEqual('3.5');
|
|
206
|
-
|
|
207
|
-
// // test market data not exisits
|
|
208
|
-
// expect(marketData1[0].rating).toEqual(null);
|
|
30
|
+
});
|
|
209
31
|
|
|
210
|
-
|
|
211
|
-
|
|
32
|
+
test("Handles missing optional fields gracefully", () => {
|
|
33
|
+
const operatorData = {
|
|
34
|
+
name: "Test Casino",
|
|
35
|
+
ribbons: [null, "customLabel", 2],
|
|
36
|
+
operator_url: "/test-url",
|
|
37
|
+
bonuses: {},
|
|
38
|
+
};
|
|
212
39
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
// expect(Object.values(transformedOperators)[0].rating).not.toEqual(marketData1[0].rating);
|
|
216
|
-
// expect(Object.values(transformedOperators)[0].rating).toEqual(generalData.rating);
|
|
217
|
-
// });
|
|
40
|
+
const operatorPage = [{}];
|
|
41
|
+
const relations = { ribbons: { 2: { label: "fromRelations" } } };
|
|
218
42
|
|
|
219
|
-
|
|
220
|
-
// const operatorsData = {
|
|
221
|
-
// yyy: {
|
|
222
|
-
// id: 1501,
|
|
223
|
-
// general_data: {
|
|
224
|
-
// id: 1501,
|
|
225
|
-
// name: "YYY Casino",
|
|
226
|
-
// short_name: "yyy",
|
|
227
|
-
// min_deposit: "10",
|
|
228
|
-
// min_withdrawal: "10",
|
|
229
|
-
// max_withdrawal: "5000",
|
|
230
|
-
// games_amount: "500+",
|
|
231
|
-
// },
|
|
232
|
-
// markets_data: {
|
|
233
|
-
// arab_en: {
|
|
234
|
-
// casino: {
|
|
235
|
-
// min_deposit: "20",
|
|
236
|
-
// min_withdrawal: "20",
|
|
237
|
-
// max_withdrawal: "10000",
|
|
238
|
-
// games_amount: "1000+",
|
|
239
|
-
// currency_ids: [1],
|
|
240
|
-
// deposit_method_ids: [1,2,],
|
|
241
|
-
// rating: "4.6",
|
|
242
|
-
// rating_casino: "5",
|
|
243
|
-
// rating_games: "4",
|
|
244
|
-
// rating_bonuses: "4",
|
|
245
|
-
// rating_customer: "5",
|
|
246
|
-
// rating_payout: "5",
|
|
247
|
-
// },
|
|
248
|
-
// },
|
|
249
|
-
// },
|
|
250
|
-
// sites_data: {
|
|
251
|
-
// arab_en: {
|
|
252
|
-
// casino: {
|
|
253
|
-
// id: 29788,
|
|
254
|
-
// market_id: 86,
|
|
255
|
-
// market: "arab_en",
|
|
256
|
-
// rating_casino: null,
|
|
257
|
-
// rating_games: "10",
|
|
258
|
-
// rating_bonuses: null,
|
|
259
|
-
// rating_customer: null,
|
|
260
|
-
// rating_payout: null,
|
|
261
|
-
// rating: "8",
|
|
262
|
-
// currency_ids: [2,3,4],
|
|
263
|
-
// country_ids: [62,23,],
|
|
264
|
-
// min_deposit: "22",
|
|
265
|
-
// min_withdrawal: "30",
|
|
266
|
-
// max_withdrawal: "20000",
|
|
267
|
-
// games_amount: "1500+",
|
|
268
|
-
// payout_time: "1-3 days",
|
|
269
|
-
// },
|
|
270
|
-
// },
|
|
271
|
-
// arab_ar: {
|
|
272
|
-
// casino: {
|
|
273
|
-
// id: 29798,
|
|
274
|
-
// market_id: 144,
|
|
275
|
-
// market: "arab_ar",
|
|
276
|
-
// rating_casino: null,
|
|
277
|
-
// rating_games: "10",
|
|
278
|
-
// rating_bonuses: null,
|
|
279
|
-
// rating_customer: null,
|
|
280
|
-
// rating_payout: null,
|
|
281
|
-
// rating: "8",
|
|
282
|
-
// currency_ids: [2,3,4],
|
|
283
|
-
// restricted_country_ids: [253],
|
|
284
|
-
// min_deposit: "22",
|
|
285
|
-
// min_withdrawal: "30",
|
|
286
|
-
// max_withdrawal: "20000",
|
|
287
|
-
// games_amount: "1500+",
|
|
288
|
-
// payout_time: "1-3 days",
|
|
289
|
-
// },
|
|
290
|
-
// },
|
|
291
|
-
// },
|
|
292
|
-
// },
|
|
293
|
-
// };
|
|
294
|
-
// const countriesData = getCountryData();
|
|
295
|
-
// const currenciesData = getCurrencyData();
|
|
43
|
+
const result = sanitizeOperatorData(operatorData, operatorPage, relations);
|
|
296
44
|
|
|
297
|
-
|
|
298
|
-
|
|
45
|
+
expect(result.name).toBe("Test Casino");
|
|
46
|
+
expect(result.url).toBe("/test-url");
|
|
47
|
+
expect(result.ribbons).toEqual(["customLabel", "fromRelations"]);
|
|
48
|
+
expect(result.author_name).toBeUndefined();
|
|
299
49
|
|
|
300
|
-
// expect(Object.keys(operatorData).length).toBe(2);
|
|
301
|
-
// });
|
|
302
50
|
});
|
|
51
|
+
});
|
|
52
|
+
|
|
303
53
|
afterEach(() => {
|
|
304
|
-
|
|
54
|
+
cleanup();
|
|
305
55
|
});
|