Skip to content

Commit a685624

Browse files
authored
fix(#39) make the test script testable on Mac OSX (#45)
change the docker-compose script so that the working directory is created under the working directory fix issues in the two test cases
1 parent c292726 commit a685624

File tree

3 files changed

+12
-9
lines changed

3 files changed

+12
-9
lines changed

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,7 @@ yarn.lock
6060
# dotenv environment variables file
6161
.env
6262

63-
.idea
63+
.idea
64+
65+
# docker files created by the docker containers for testing
66+
tmp

dcm4chee-docker-compose.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ services:
1010
- "389"
1111
env_file: dcm4chee-docker-compose.env
1212
volumes:
13-
- /tmp/dcm4chee-arc/ldap:/var/lib/ldap
14-
- /tmp/dcm4chee-arc/slapd.d:/etc/ldap/slapd.d
13+
- ./tmp/dcm4chee-arc/ldap:/var/lib/ldap
14+
- ./tmp/dcm4chee-arc/slapd.d:/etc/ldap/slapd.d
1515
db:
1616
image: dcm4che/postgres-dcm4chee:10.0-13
1717
logging:
@@ -22,7 +22,7 @@ services:
2222
- "5432"
2323
env_file: dcm4chee-docker-compose.env
2424
volumes:
25-
- /tmp/dcm4chee-arc/db:/var/lib/postgresql/data
25+
- ./tmp/dcm4chee-arc/db:/var/lib/postgresql/data
2626
arc:
2727
image: dcm4che/dcm4chee-arc-psql:5.13.3
2828
logging:
@@ -39,5 +39,5 @@ services:
3939
- ldap
4040
- db
4141
volumes:
42-
- /tmp/dcm4chee-arc/wildfly:/opt/wildfly/standalone
43-
- /tmp/dcm4chee-arc/storage:/storage
42+
- ./tmp/dcm4chee-arc/wildfly:/opt/wildfly/standalone
43+
- ./tmp/dcm4chee-arc/storage:/storage

test/test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ describe('dicomweb.api.DICOMwebClient', function() {
7272
};
7373

7474
await dwc.storeInstances(options);
75-
}, 10000);
75+
}, 20000);
7676

7777
it('should find four studes', async function() {
7878
const studies = await dwc.searchForStudies();
@@ -165,7 +165,7 @@ describe('dicomweb.api.DICOMwebClient', function() {
165165
url,
166166
requestHooks: [requestHook1Spy, requestHook2Spy]
167167
});
168-
const metadata = { url: metadataUrl, method: 'get' };
168+
const metadata = { url: metadataUrl, method: 'get', headers: {} };
169169
request.open('GET', metadata.url);
170170
await dwc.retrieveInstanceMetadata({
171171
studyInstanceUID: '999.999.3859744',
@@ -181,7 +181,7 @@ describe('dicomweb.api.DICOMwebClient', function() {
181181
url,
182182
requestHooks: [requestHook1Spy, requestHook2Spy]
183183
});
184-
const metadata = { url: metadataUrl, method: 'get' };
184+
const metadata = { url: metadataUrl, method: 'get', headers: {} };
185185
request.open('GET', metadata.url);
186186
await dwc.retrieveInstanceMetadata({
187187
studyInstanceUID: '999.999.3859744',

0 commit comments

Comments
 (0)