@@ -52,8 +52,8 @@ exports.addFramework = {
5252
5353 test . equal ( fileRefEntry . isa , 'PBXFileReference' ) ;
5454 test . equal ( fileRefEntry . lastKnownFileType , '"compiled.mach-o.dylib"' ) ;
55- test . equal ( fileRefEntry . name , 'libsqlite3.dylib' ) ;
56- test . equal ( fileRefEntry . path , 'usr/lib/libsqlite3.dylib' ) ;
55+ test . equal ( fileRefEntry . name , '" libsqlite3.dylib" ' ) ;
56+ test . equal ( fileRefEntry . path , '" usr/lib/libsqlite3.dylib" ' ) ;
5757 test . equal ( fileRefEntry . sourceTree , 'SDKROOT' ) ;
5858
5959 test . done ( ) ;
@@ -85,9 +85,22 @@ exports.addFramework = {
8585 test . equal ( buildFileEntry . isa , 'PBXBuildFile' ) ;
8686 test . equal ( buildFileEntry . fileRef , newFile . fileRef ) ;
8787 test . equal ( buildFileEntry . fileRef_comment , 'libsqlite3.dylib' ) ;
88+ test . equal ( buildFileEntry . settings , undefined ) ;
8889
8990 test . done ( ) ;
9091 } ,
92+ 'should add the PBXBuildFile object correctly /w weak linked frameworks' : function ( test ) {
93+ var newFile = proj . addFramework ( 'libsqlite3.dylib' , { weak : true } ) ,
94+ buildFileSection = proj . pbxBuildFileSection ( ) ,
95+ buildFileEntry = buildFileSection [ newFile . uuid ] ;
96+
97+ test . equal ( buildFileEntry . isa , 'PBXBuildFile' ) ;
98+ test . equal ( buildFileEntry . fileRef , newFile . fileRef ) ;
99+ test . equal ( buildFileEntry . fileRef_comment , 'libsqlite3.dylib' ) ;
100+ test . deepEqual ( buildFileEntry . settings , { ATTRIBUTES : [ 'Weak' ] } ) ;
101+
102+ test . done ( ) ;
103+ } ,
91104 'should add to the Frameworks PBXGroup' : function ( test ) {
92105 var newLength = proj . pbxGroupByName ( 'Frameworks' ) . children . length + 1 ,
93106 newFile = proj . addFramework ( 'libsqlite3.dylib' ) ,
0 commit comments