Skip to content

Commit

Permalink
Merge pull request #990 from Chia-Network/hotfix/replace-defunct-url-…
Browse files Browse the repository at this point in the history
…in-tests

tests: Replace broken URL in tests
  • Loading branch information
TheLastCicada authored Jan 13, 2024
2 parents 0b80748 + c4420fa commit 96d65f2
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 14 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ on:
branches:
- '**'

env:
PICKLIST_URL: https://climate-warehouse.s3.us-west-2.amazonaws.com/public/picklists.json

jobs:
test:
name: NPM Tests
Expand Down
4 changes: 2 additions & 2 deletions docs/cadt_rpc_api.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ curl --location --request GET 'localhost:31310/v1/organizations' --header 'Conte
"77641db780adc6c74f1ff357804e26a799e4a09157f426aac588963a39bdb2d9":{
"orgUid":"77641db780adc6c74f1ff357804e26a799e4a09157f426aac588963a39bdb2d9",
"name":"Org Test",
"icon":"https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg",
"icon":"https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg",
"isHome":true,
"subscribed":true
}
Expand All @@ -130,7 +130,7 @@ curl --location -g --request POST 'localhost:31310/v1/organizations/' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "Sample Org",
"icon": "https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg"
"icon": "https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg"
}'

// Response
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cadt",
"version": "1.7.6",
"version": "1.7.7",
"_comment": "DONT CHANGE MAJOR UNLESS DATAMODEL CHANGES: The major version corresponds to the datamodel version your using, so 2.0.0 means it'll use datamodel v2",
"private": true,
"bin": "build/server.js",
Expand Down
6 changes: 3 additions & 3 deletions src/models/organizations/organizations.stub.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export default [
name: 'My Org',
registryId:
'9144c974e146920088514534c89371dc269d1b894a2c7f6cedeb80b804c6cd02',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
subscribed: true,
isHome: true,
},
Expand All @@ -13,7 +13,7 @@ export default [
name: 'Earl Registry',
registryId:
'047b74ea567f7591f463f29dcec4cab1e760ef181c006fb3865a3e20ca6144aa',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/austria.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
subscribed: false,
isHome: false,
},
Expand All @@ -22,7 +22,7 @@ export default [
name: 'Kyles Org Registry',
registryId:
'eb9f9440f11f2705dd97da824f6f27079cbde3ad4ff4252539f17c8f0c08a4f9',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/denmark.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
subscribed: false,
isHome: false,
},
Expand Down
4 changes: 2 additions & 2 deletions tests/resources/organization.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ describe('Orgainzation Resource CRUD', function () {

const response = await supertest(app).post(`/v1/organizations`).send({
name: 'My Org',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
});

expect(response.body.message).to.equal(
Expand All @@ -56,7 +56,7 @@ describe('Orgainzation Resource CRUD', function () {

expect(Object.values(response.body)[0].name).to.equal('My Org');
expect(Object.values(response.body)[0].icon).to.equal(
'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
);
}).timeout(TEST_WAIT_TIME * 10);
});
Expand Down
4 changes: 2 additions & 2 deletions tests/resources/projects.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ describe('Project Resource CRUD', function () {

await supertest(app).post(`/v1/organizations`).send({
name: 'Test',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
});
});

Expand Down Expand Up @@ -249,7 +249,7 @@ describe('Project Resource CRUD', function () {

await supertest(app).post(`/v1/organizations`).send({
name: 'Test',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
});
}).timeout(TEST_WAIT_TIME * 10);
it('errors if there is a current set of pending commits', function () {});
Expand Down
2 changes: 1 addition & 1 deletion tests/test-fixtures/organization-fixtures.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import app from '../../src/server';
export const createTestHomeOrg = async () => {
const response = await supertest(app).post(`/v1/organizations`).send({
name: 'My Org',
icon: 'https://climate-warehouse.s3.us-west-2.amazonaws.com/public/orgs/me.svg',
icon: 'https://www.chia.net/wp-content/uploads/2023/01/chia-logo-dark.svg',
});

console.log('Creating home org', response.body);
Expand Down

0 comments on commit 96d65f2

Please sign in to comment.