Skip to content

Commit f5a41ec

Browse files
committed
Disable highlight & fix some other tests.
1 parent ad87d27 commit f5a41ec

File tree

6 files changed

+216
-199
lines changed

6 files changed

+216
-199
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,13 @@ Today, Mobile Minting supports the following creator platforms:
6868
Base
6969
</td>
7070
<td>
71-
71+
💥 Failing
7272
</td>
7373
<td>
74-
74+
💥 Failing
7575
</td>
7676
<td>
77-
77+
💥 Failing
7878
</td>
7979
</tr>
8080
<tr>

src/ingestors/highlight/index.ts

Lines changed: 26 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -15,32 +15,34 @@ const CONTRACT_ADDRESS = '0x8087039152c472Fa74F47398628fF002994056EA';
1515

1616
export class HighlightIngestor implements MintIngestor {
1717
async supportsUrl(resources: MintIngestorResources, url: string): Promise<boolean> {
18-
const id = url.split('/').pop();
19-
if (!id) {
20-
return false;
21-
}
22-
23-
const collection = await getHighlightCollectionById(resources, id);
24-
25-
if (!collection || collection.chainId !== 8453) {
26-
return false;
27-
}
28-
29-
const urlPattern = /^https:\/\/highlight\.xyz\/mint\/[a-f0-9]{24}$/;
30-
return (
31-
new URL(url).hostname === 'www.highlight.xyz' || new URL(url).hostname === 'highlight.xyz' || urlPattern.test(url)
32-
);
18+
return false;
19+
// const id = url.split('/').pop();
20+
// if (!id) {
21+
// return false;
22+
// }
23+
24+
// const collection = await getHighlightCollectionById(resources, id);
25+
26+
// if (!collection || collection.chainId !== 8453) {
27+
// return false;
28+
// }
29+
30+
// const urlPattern = /^https:\/\/highlight\.xyz\/mint\/[a-f0-9]{24}$/;
31+
// return (
32+
// new URL(url).hostname === 'www.highlight.xyz' || new URL(url).hostname === 'highlight.xyz' || urlPattern.test(url)
33+
// );
3334
}
3435

3536
async supportsContract(resources: MintIngestorResources, contractOptions: MintContractOptions): Promise<boolean> {
36-
if (contractOptions.chainId !== 8453) {
37-
return false;
38-
}
39-
const collection = await getHighlightCollectionByAddress(resources, contractOptions);
40-
if (!collection) {
41-
return false;
42-
}
43-
return true;
37+
return false;
38+
// if (contractOptions.chainId !== 8453) {
39+
// return false;
40+
// }
41+
// const collection = await getHighlightCollectionByAddress(resources, contractOptions);
42+
// if (!collection) {
43+
// return false;
44+
// }
45+
// return true;
4446
}
4547

4648
async createMintForContract(
@@ -80,7 +82,7 @@ export class HighlightIngestor implements MintIngestor {
8082
throw new MintIngestorError(MintIngestionErrorName.MissingRequiredData, 'Error finding creator');
8183
}
8284

83-
const collectionId = collection.highlightCollection?.id;
85+
const collectionId = collection.highlightCollection?.id || collection.id;
8486

8587
if (!collectionId) {
8688
throw new MintIngestorError(MintIngestionErrorName.MissingRequiredData, 'Collection id not available');

src/ingestors/highlight/offchain-metadata.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ export const getHighlightCollectionById = async (
2727
marketplaceId
2828
accountId
2929
address
30-
symbol
3130
chainId
3231
status
3332
baseUri

test/ingestors/foundation.test.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,9 @@ describe('foundation', function () {
6666
expect(mintInstructions.contractParams).to.equal(
6767
'["0x89E63F58da71E9CD4DA439C3D1194917c67eb869", 1, address, "0x0000000000000000000000000000000000000000"]',
6868
);
69-
expect(mintInstructions.priceWei).to.equal('7700000000000000');
69+
70+
// This has now ended and the API returns 0 for the price
71+
expect(mintInstructions.priceWei).to.equal('0');
7072

7173
expect(template.featuredImageUrl).to.equal(
7274
'https://f8n-production-collection-assets.imgix.net/8453/0x89E63F58da71E9CD4DA439C3D1194917c67eb869/pre_reveal/nft.jpg',

test/ingestors/highlight.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { basicIngestorTests } from '../shared/basic-ingestor-tests';
77

88
const resources = mintIngestorResources();
99

10-
describe('highlight', function () {
10+
describe.skip('highlight', function () {
1111
basicIngestorTests(
1212
new HighlightIngestor(),
1313
resources,

0 commit comments

Comments
 (0)