@@ -5,15 +5,10 @@ import uuidv4 from "uuid/v4";
55import {
66 MapiContactAsFileRequest ,
77 MapiContactDto ,
8- MapiContactElectronicAddressDto ,
9- MapiContactElectronicAddressPropertySetDto ,
108 MapiContactFromFileRequest ,
119 MapiContactGetRequest ,
12- MapiContactNamePropertySetDto ,
13- MapiContactPersonalInfoPropertySetDto ,
14- MapiContactProfessionalPropertySetDto ,
1510 MapiContactSaveRequest ,
16- MapiContactTelephonePropertySetDto ,
11+ Models ,
1712 StorageFileLocation
1813} from ".." ;
1914
@@ -50,19 +45,25 @@ describe('MAPI contact tests', function () {
5045 } ) ;
5146
5247 function getMapiContactDto ( ) : MapiContactDto {
53- const mapiContactDto = new MapiContactDto ( ) ;
54- mapiContactDto . electronicAddresses = new MapiContactElectronicAddressPropertySetDto ( ) ;
55- mapiContactDto . electronicAddresses . defaultEmailAddress = new MapiContactElectronicAddressDto ( ) ;
56- mapiContactDto . electronicAddresses . defaultEmailAddress . emailAddress = "email@aspose.com" ;
57- mapiContactDto . nameInfo = new MapiContactNamePropertySetDto ( ) ;
58- mapiContactDto . nameInfo . givenName = "Alex" ;
59- mapiContactDto . nameInfo . surname = "Thomas" ;
60- mapiContactDto . personalInfo = new MapiContactPersonalInfoPropertySetDto ( ) ;
61- mapiContactDto . personalInfo . businessHomePage = "www.aspose.com" ;
62- mapiContactDto . professionalInfo = new MapiContactProfessionalPropertySetDto ( ) ;
63- mapiContactDto . professionalInfo . profession = "GENERAL DIRECTOR" ;
64- mapiContactDto . telephones = new MapiContactTelephonePropertySetDto ( ) ;
65- mapiContactDto . telephones . primaryTelephoneNumber = "+49 211 4247 21" ;
66- return mapiContactDto ;
48+ return Models . mapiContactDto ( )
49+ . electronicAddresses ( Models . mapiContactElectronicAddressPropertySetDto ( )
50+ . defaultEmailAddress ( Models . mapiContactElectronicAddressDto ( )
51+ . emailAddress ( 'email@aspose.com' )
52+ . build ( ) )
53+ . build ( ) )
54+ . nameInfo ( Models . mapiContactNamePropertySetDto ( )
55+ . givenName ( 'Alex' )
56+ . surname ( 'Thomas' )
57+ . build ( ) )
58+ . personalInfo ( Models . mapiContactPersonalInfoPropertySetDto ( )
59+ . businessHomePage ( 'www.aspose.com' )
60+ . build ( ) )
61+ . professionalInfo ( Models . mapiContactProfessionalPropertySetDto ( )
62+ . profession ( 'GENERAL DIRECTOR' )
63+ . build ( ) )
64+ . telephones ( Models . mapiContactTelephonePropertySetDto ( )
65+ . primaryTelephoneNumber ( '+49 211 4247 21' )
66+ . build ( ) )
67+ . build ( ) ;
6768 }
6869} ) ;
0 commit comments