@@ -8,22 +8,22 @@ const testCase2 = require('./data/testCase2.json');
88const testCase3 = require ( './data/testCase3.json' ) ;
99const testCases = [ testCase1 , testCase2 , testCase3 ] ;
1010
11- const dicomMicroscopyViewer = require ( '../build/dicom-microscopy-viewer.js' ) ;
11+ const dmv = require ( '../build/dicom-microscopy-viewer.js' ) ;
1212
1313
14- describe ( 'dicomMicroscopyViewer .viewer.VolumeImageViewer' , ( ) => {
14+ describe ( 'dmv .viewer.VolumeImageViewer' , ( ) => {
1515
1616 var viewer ;
1717 testCases . forEach ( ( metadata , index ) => {
1818 console . log ( `run test case #${ index + 1 } ` )
1919 before ( ( ) => {
20- viewer = new dicomMicroscopyViewer . api . VLWholeSlideMicroscopyImageViewer ( {
20+ viewer = new dmv . api . VLWholeSlideMicroscopyImageViewer ( {
2121 client : 'test' ,
2222 metadata : metadata ,
2323 } ) ;
2424 } )
2525
26- const ellipse = new dicomMicroscopyViewer . scoord3d . Ellipse ( {
26+ const ellipse = new dmv . scoord3d . Ellipse ( {
2727 coordinates : [
2828 [ 8.0 , 9.2 , 0 ] ,
2929 [ 8.8 , 9.2 , 0 ] ,
@@ -32,11 +32,11 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
3232 ] ,
3333 frameOfReferenceUID : '1.2.3'
3434 } ) ;
35- const point = new dicomMicroscopyViewer . scoord3d . Point ( {
35+ const point = new dmv . scoord3d . Point ( {
3636 coordinates : [ 9.0467 , 8.7631 , 0 ] ,
3737 frameOfReferenceUID : '1.2.3'
3838 } ) ;
39- const box = new dicomMicroscopyViewer . scoord3d . Polygon ( {
39+ const box = new dmv . scoord3d . Polygon ( {
4040 coordinates : [
4141 [ 8.8824 , 8.8684 , 0 ] ,
4242 [ 9.2255 , 9.9634 , 0 ] ,
@@ -46,7 +46,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
4646 ] ,
4747 frameOfReferenceUID : '1.2.3'
4848 } )
49- const polygon = new dicomMicroscopyViewer . scoord3d . Polygon ( {
49+ const polygon = new dmv . scoord3d . Polygon ( {
5050 coordinates : [
5151 [ 7.8326 , 8.4428 , 0 ] ,
5252 [ 7.1919 , 7.9169 , 0 ] ,
@@ -55,7 +55,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
5555 ] ,
5656 frameOfReferenceUID : '1.2.3'
5757 } )
58- const freehandPolygon = new dicomMicroscopyViewer . scoord3d . Polygon ( {
58+ const freehandPolygon = new dmv . scoord3d . Polygon ( {
5959 coordinates : [
6060 [ 6.9340 , 7.0669 , 0 ] ,
6161 [ 6.9340 , 7.0669 , 0 ] ,
@@ -74,14 +74,14 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
7474 ] ,
7575 frameOfReferenceUID : '1.2.3'
7676 } )
77- const line = new dicomMicroscopyViewer . scoord3d . Polyline ( {
77+ const line = new dmv . scoord3d . Polyline ( {
7878 coordinates : [
7979 [ 7.0442 , 7.5295 , 0 ] ,
8080 [ 7.6725 , 7.0580 , 0 ]
8181 ] ,
8282 frameOfReferenceUID : '1.2.3'
8383 } )
84- const freeHandLine = new dicomMicroscopyViewer . scoord3d . Polyline ( {
84+ const freeHandLine = new dmv . scoord3d . Polyline ( {
8585 coordinates : [
8686 [ 6.6769 , 9.1169 , 0 ] ,
8787 [ 6.6769 , 9.1169 , 0 ] ,
@@ -105,7 +105,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
105105 } )
106106
107107 it ( 'should add property to ROI upon construction' , ( ) => {
108- const roi = new dicomMicroscopyViewer . roi . ROI ( {
108+ const roi = new dmv . roi . ROI ( {
109109 scoord3d : point ,
110110 properties : { foo : 'bar' }
111111 } ) ;
@@ -135,7 +135,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
135135 } ] ,
136136 ValueType : 'CODE' ,
137137 }
138- const roi = new dicomMicroscopyViewer . roi . ROI ( {
138+ const roi = new dmv . roi . ROI ( {
139139 scoord3d : point ,
140140 properties : {
141141 'evaluations' : [ evaluation ]
@@ -166,7 +166,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
166166 } ] ,
167167 ValueType : 'CODE' ,
168168 }
169- const roi = new dicomMicroscopyViewer . roi . ROI ( {
169+ const roi = new dmv . roi . ROI ( {
170170 scoord3d : point
171171 } ) ;
172172 assert . deepEqual (
@@ -207,7 +207,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
207207 } ] ,
208208 ValueType : 'CODE' ,
209209 }
210- const roi = new dicomMicroscopyViewer . roi . ROI ( {
210+ const roi = new dmv . roi . ROI ( {
211211 scoord3d : point ,
212212 properties : { measurements : [ measurement ] }
213213 } ) ;
@@ -239,7 +239,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
239239 } ] ,
240240 ValueType : 'CODE' ,
241241 }
242- const roi = new dicomMicroscopyViewer . roi . ROI ( {
242+ const roi = new dmv . roi . ROI ( {
243243 scoord3d : point
244244 } ) ;
245245 assert . deepEqual (
@@ -264,7 +264,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
264264 } )
265265
266266 it ( 'should create a Point ROI and return it back successfuly' , ( ) => {
267- const roi = new dicomMicroscopyViewer . roi . ROI ( {
267+ const roi = new dmv . roi . ROI ( {
268268 scoord3d : point
269269 } ) ;
270270 viewer . addROI ( roi ) ;
@@ -290,7 +290,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
290290 } )
291291
292292 it ( 'should create a Box ROI and return it back successfuly' , ( ) => {
293- const roi = new dicomMicroscopyViewer . roi . ROI ( {
293+ const roi = new dmv . roi . ROI ( {
294294 scoord3d : box ,
295295 properties : { 'foo' : 'bar' }
296296 } ) ;
@@ -349,7 +349,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
349349 } )
350350
351351 it ( 'should create a Polygon ROI and return it back successfuly' , ( ) => {
352- const roi = new dicomMicroscopyViewer . roi . ROI ( {
352+ const roi = new dmv . roi . ROI ( {
353353 scoord3d : polygon
354354 } ) ;
355355 viewer . addROI ( roi ) ;
@@ -360,7 +360,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
360360 } )
361361
362362 it ( 'should create a Freehand Polygon ROI and return it back successfuly' , ( ) => {
363- const roi = new dicomMicroscopyViewer . roi . ROI ( {
363+ const roi = new dmv . roi . ROI ( {
364364 scoord3d : freehandPolygon
365365 } ) ;
366366 viewer . addROI ( roi ) ;
@@ -371,7 +371,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
371371 } )
372372
373373 it ( 'should create a Line ROI and return it back successfuly' , ( ) => {
374- const roi = new dicomMicroscopyViewer . roi . ROI ( {
374+ const roi = new dmv . roi . ROI ( {
375375 scoord3d : line
376376 } ) ;
377377 viewer . addROI ( roi ) ;
@@ -382,7 +382,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
382382 } )
383383
384384 it ( 'should create a FreehandLine ROI and return it back successfuly' , ( ) => {
385- const roi = new dicomMicroscopyViewer . roi . ROI ( {
385+ const roi = new dmv . roi . ROI ( {
386386 scoord3d : freeHandLine
387387 } ) ;
388388 viewer . addROI ( roi ) ;
@@ -414,7 +414,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
414414 } )
415415
416416 it ( 'should create an Ellipse ROI and return it back successfuly' , ( ) => {
417- const roi = new dicomMicroscopyViewer . roi . ROI ( {
417+ const roi = new dmv . roi . ROI ( {
418418 scoord3d : ellipse
419419 } ) ;
420420 viewer . addROI ( roi ) ;
@@ -435,7 +435,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
435435
436436 it ( 'should throw an error if uid of ROI is undefined' , ( ) => {
437437 assert . throws ( function ( ) {
438- const roi = new dicomMicroscopyViewer . roi . ROI ( {
438+ const roi = new dmv . roi . ROI ( {
439439 scoord3d : point ,
440440 uid : undefined ,
441441 properties : { }
@@ -447,7 +447,7 @@ describe('dicomMicroscopyViewer.viewer.VolumeImageViewer', ()=> {
447447
448448 it ( 'should throw an error if uid of ROI is null' , ( ) => {
449449 assert . throws ( function ( ) {
450- const roi = new dicomMicroscopyViewer . roi . ROI ( {
450+ const roi = new dmv . roi . ROI ( {
451451 scoord3d : point ,
452452 uid : null ,
453453 properties : { }
0 commit comments