diff options
Diffstat (limited to 'linden/indra/test')
25 files changed, 2094 insertions, 279 deletions
diff --git a/linden/indra/test/MacTester.xcodeproj/project.pbxproj b/linden/indra/test/MacTester.xcodeproj/project.pbxproj index 77ba7c2..76bdc0a 100644 --- a/linden/indra/test/MacTester.xcodeproj/project.pbxproj +++ b/linden/indra/test/MacTester.xcodeproj/project.pbxproj | |||
@@ -45,8 +45,11 @@ | |||
45 | DA306B580ACD9F3F008D9B2F /* lltiming_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B540ACD9F3F008D9B2F /* lltiming_tut.cpp */; }; | 45 | DA306B580ACD9F3F008D9B2F /* lltiming_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B540ACD9F3F008D9B2F /* lltiming_tut.cpp */; }; |
46 | DA306B590ACD9F3F008D9B2F /* lluri_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B550ACD9F3F008D9B2F /* lluri_tut.cpp */; }; | 46 | DA306B590ACD9F3F008D9B2F /* lluri_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B550ACD9F3F008D9B2F /* lluri_tut.cpp */; }; |
47 | DA306B5C0ACD9F6F008D9B2F /* llhttpclient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B5B0ACD9F6F008D9B2F /* llhttpclient.cpp */; }; | 47 | DA306B5C0ACD9F6F008D9B2F /* llhttpclient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA306B5B0ACD9F6F008D9B2F /* llhttpclient.cpp */; }; |
48 | DA4D18170B567E0D0049C10F /* llformat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA4D18150B567E0D0049C10F /* llformat.cpp */; }; | ||
49 | DA4D18180B567E0D0049C10F /* llformat.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = DA4D18160B567E0D0049C10F /* llformat.h */; }; | ||
50 | DA4D182D0B567ED70049C10F /* llerrorcontrol.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = DA4D182B0B567ED70049C10F /* llerrorcontrol.h */; }; | ||
51 | DA9C40480B540D8A00DD6F44 /* lllivefile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DA9C40460B540D8A00DD6F44 /* lllivefile.cpp */; }; | ||
48 | DAD1C4CC0AE2C78C0054574C /* stats.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DAD1C4CB0AE2C78C0054574C /* stats.cpp */; }; | 52 | DAD1C4CC0AE2C78C0054574C /* stats.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DAD1C4CB0AE2C78C0054574C /* stats.cpp */; }; |
49 | DAD1C4DE0AE2CA0C0054574C /* llcurl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = DAD1C4DD0AE2CA0C0054574C /* llcurl.cpp */; }; | ||
50 | FD15584D0A06BE2E00DE9AE5 /* io.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD15584C0A06BE2E00DE9AE5 /* io.cpp */; }; | 53 | FD15584D0A06BE2E00DE9AE5 /* io.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD15584C0A06BE2E00DE9AE5 /* io.cpp */; }; |
51 | FD15585C0A06BEB000DE9AE5 /* llbuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558500A06BEB000DE9AE5 /* llbuffer.cpp */; }; | 54 | FD15585C0A06BEB000DE9AE5 /* llbuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558500A06BEB000DE9AE5 /* llbuffer.cpp */; }; |
52 | FD15585E0A06BEB000DE9AE5 /* llbufferstream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558520A06BEB000DE9AE5 /* llbufferstream.cpp */; }; | 55 | FD15585E0A06BEB000DE9AE5 /* llbufferstream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558520A06BEB000DE9AE5 /* llbufferstream.cpp */; }; |
@@ -84,6 +87,11 @@ | |||
84 | FD155F5D0A08FB5100DE9AE5 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = FD155F480A08FB5100DE9AE5 /* Carbon.framework */; }; | 87 | FD155F5D0A08FB5100DE9AE5 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = FD155F480A08FB5100DE9AE5 /* Carbon.framework */; }; |
85 | FD155F610A08FD5900DE9AE5 /* llfasttimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */; }; | 88 | FD155F610A08FD5900DE9AE5 /* llfasttimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */; }; |
86 | FD155F670A08FD9100DE9AE5 /* message_string_table.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F660A08FD9100DE9AE5 /* message_string_table.cpp */; }; | 89 | FD155F670A08FD9100DE9AE5 /* message_string_table.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F660A08FD9100DE9AE5 /* message_string_table.cpp */; }; |
90 | FD23FEB90B4340F3007A29CA /* llhttpnode_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD23FEB70B4340F3007A29CA /* llhttpnode_tut.cpp */; }; | ||
91 | FD23FEBA0B4340F3007A29CA /* lluserrelations_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD23FEB80B4340F3007A29CA /* lluserrelations_tut.cpp */; }; | ||
92 | FD23FEBE0B43410C007A29CA /* lluserrelations.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD23FEBC0B43410C007A29CA /* lluserrelations.cpp */; }; | ||
93 | FD23FEBF0B43410C007A29CA /* lluserrelations.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = FD23FEBD0B43410C007A29CA /* lluserrelations.h */; }; | ||
94 | FD23FEC60B4341E2007A29CA /* llerror_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD23FEC50B4341E2007A29CA /* llerror_tut.cpp */; }; | ||
87 | FD396CDD0A1D37DF005DCB1F /* lltut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD396CDC0A1D37DF005DCB1F /* lltut.cpp */; }; | 95 | FD396CDD0A1D37DF005DCB1F /* lltut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD396CDC0A1D37DF005DCB1F /* lltut.cpp */; }; |
88 | FD396D160A1DFB4B005DCB1F /* reflection_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 386A940D0A0B5F60001DE10D /* reflection_tut.cpp */; }; | 96 | FD396D160A1DFB4B005DCB1F /* reflection_tut.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 386A940D0A0B5F60001DE10D /* reflection_tut.cpp */; }; |
89 | FD506A0609FEB58900E297C2 /* llsdserialize.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD506A0409FEB58900E297C2 /* llsdserialize.cpp */; }; | 97 | FD506A0609FEB58900E297C2 /* llsdserialize.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD506A0409FEB58900E297C2 /* llsdserialize.cpp */; }; |
@@ -97,8 +105,6 @@ | |||
97 | FD5DFA9109C1DF3E007E3F78 /* lldate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */; }; | 105 | FD5DFA9109C1DF3E007E3F78 /* lldate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */; }; |
98 | FD5DFA9309C1DF4E007E3F78 /* lluuid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9209C1DF4E007E3F78 /* lluuid.cpp */; }; | 106 | FD5DFA9309C1DF4E007E3F78 /* lluuid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9209C1DF4E007E3F78 /* lluuid.cpp */; }; |
99 | FD5DFA9909C1DFB7007E3F78 /* lluri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */; }; | 107 | FD5DFA9909C1DFB7007E3F78 /* lluri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */; }; |
100 | FD5DFAA009C1DFE2007E3F78 /* llerrorbuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9C09C1DFE2007E3F78 /* llerrorbuffer.cpp */; }; | ||
101 | FD5DFAA209C1DFE2007E3F78 /* llerrorstream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9E09C1DFE2007E3F78 /* llerrorstream.cpp */; }; | ||
102 | FD5DFAA609C1E01D007E3F78 /* llmd5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */; }; | 108 | FD5DFAA609C1E01D007E3F78 /* llmd5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */; }; |
103 | FD5DFAA909C1E056007E3F78 /* llerror.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA809C1E056007E3F78 /* llerror.cpp */; }; | 109 | FD5DFAA909C1E056007E3F78 /* llerror.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA809C1E056007E3F78 /* llerror.cpp */; }; |
104 | FD5DFAAC09C1E09F007E3F78 /* llrand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAAB09C1E09F007E3F78 /* llrand.cpp */; }; | 110 | FD5DFAAC09C1E09F007E3F78 /* llrand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAAB09C1E09F007E3F78 /* llrand.cpp */; }; |
@@ -144,8 +150,6 @@ | |||
144 | FDBC10740AEEC40F00ED2E62 /* libexpat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FD506ADA09FFE09700E297C2 /* libexpat.a */; }; | 150 | FDBC10740AEEC40F00ED2E62 /* libexpat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FD506ADA09FFE09700E297C2 /* libexpat.a */; }; |
145 | FDBC10750AEEC41600ED2E62 /* lldate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */; }; | 151 | FDBC10750AEEC41600ED2E62 /* lldate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */; }; |
146 | FDBC10760AEEC41B00ED2E62 /* llmd5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */; }; | 152 | FDBC10760AEEC41B00ED2E62 /* llmd5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */; }; |
147 | FDBC10790AEEC42B00ED2E62 /* llerrorstream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9E09C1DFE2007E3F78 /* llerrorstream.cpp */; }; | ||
148 | FDBC107A0AEEC42C00ED2E62 /* llerrorbuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9C09C1DFE2007E3F78 /* llerrorbuffer.cpp */; }; | ||
149 | FDBC107B0AEEC43200ED2E62 /* lluri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */; }; | 153 | FDBC107B0AEEC43200ED2E62 /* lluri.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */; }; |
150 | FDBC107E0AEEC45100ED2E62 /* lltimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAB209C1E11A007E3F78 /* lltimer.cpp */; }; | 154 | FDBC107E0AEEC45100ED2E62 /* lltimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DFAB209C1E11A007E3F78 /* lltimer.cpp */; }; |
151 | FDBC107F0AEEC45400ED2E62 /* llfasttimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */; }; | 155 | FDBC107F0AEEC45400ED2E62 /* llfasttimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */; }; |
@@ -171,6 +175,7 @@ | |||
171 | FDBC10AD0AEEC67700ED2E62 /* llframetimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558910A06C01400DE9AE5 /* llframetimer.cpp */; }; | 175 | FDBC10AD0AEEC67700ED2E62 /* llframetimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD1558910A06C01400DE9AE5 /* llframetimer.cpp */; }; |
172 | FDCB2A670AF80D9000C44EBA /* llprocessor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */; }; | 176 | FDCB2A670AF80D9000C44EBA /* llprocessor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */; }; |
173 | FDCB2A680AF80D9000C44EBA /* llprocessor.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = FDCB2A660AF80D9000C44EBA /* llprocessor.h */; }; | 177 | FDCB2A680AF80D9000C44EBA /* llprocessor.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = FDCB2A660AF80D9000C44EBA /* llprocessor.h */; }; |
178 | FDE7AD540B7D047700C56FE0 /* llcurl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FDE7AD520B7D047700C56FE0 /* llcurl.cpp */; }; | ||
174 | FDEC4F5509F7EF7A007BAEEC /* llsd.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DF9BE09C0A68F007E3F78 /* llsd.cpp */; }; | 179 | FDEC4F5509F7EF7A007BAEEC /* llsd.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FD5DF9BE09C0A68F007E3F78 /* llsd.cpp */; }; |
175 | FDFAD4210AFFFCC30048A0C7 /* llhttpnode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FDFAD41F0AFFFCC30048A0C7 /* llhttpnode.cpp */; }; | 180 | FDFAD4210AFFFCC30048A0C7 /* llhttpnode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FDFAD41F0AFFFCC30048A0C7 /* llhttpnode.cpp */; }; |
176 | FDFAD4220AFFFCC30048A0C7 /* llhttpnode.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = FDFAD4200AFFFCC30048A0C7 /* llhttpnode.h */; }; | 181 | FDFAD4220AFFFCC30048A0C7 /* llhttpnode.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = FDFAD4200AFFFCC30048A0C7 /* llhttpnode.h */; }; |
@@ -216,6 +221,9 @@ | |||
216 | FDFAD4220AFFFCC30048A0C7 /* llhttpnode.h in CopyFiles */, | 221 | FDFAD4220AFFFCC30048A0C7 /* llhttpnode.h in CopyFiles */, |
217 | 91469E820B4486F20009E8F9 /* llmime.h in CopyFiles */, | 222 | 91469E820B4486F20009E8F9 /* llmime.h in CopyFiles */, |
218 | 91469E8E0B4489420009E8F9 /* llquaternion.h in CopyFiles */, | 223 | 91469E8E0B4489420009E8F9 /* llquaternion.h in CopyFiles */, |
224 | FD23FEBF0B43410C007A29CA /* lluserrelations.h in CopyFiles */, | ||
225 | DA4D18180B567E0D0049C10F /* llformat.h in CopyFiles */, | ||
226 | DA4D182D0B567ED70049C10F /* llerrorcontrol.h in CopyFiles */, | ||
219 | ); | 227 | ); |
220 | runOnlyForDeploymentPostprocessing = 1; | 228 | runOnlyForDeploymentPostprocessing = 1; |
221 | }; | 229 | }; |
@@ -252,10 +260,13 @@ | |||
252 | DA306B540ACD9F3F008D9B2F /* lltiming_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lltiming_tut.cpp; sourceTree = "<group>"; }; | 260 | DA306B540ACD9F3F008D9B2F /* lltiming_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lltiming_tut.cpp; sourceTree = "<group>"; }; |
253 | DA306B550ACD9F3F008D9B2F /* lluri_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluri_tut.cpp; sourceTree = "<group>"; }; | 261 | DA306B550ACD9F3F008D9B2F /* lluri_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluri_tut.cpp; sourceTree = "<group>"; }; |
254 | DA306B5B0ACD9F6F008D9B2F /* llhttpclient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llhttpclient.cpp; sourceTree = "<group>"; }; | 262 | DA306B5B0ACD9F6F008D9B2F /* llhttpclient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llhttpclient.cpp; sourceTree = "<group>"; }; |
263 | DA4D18150B567E0D0049C10F /* llformat.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llformat.cpp; sourceTree = "<group>"; }; | ||
264 | DA4D18160B567E0D0049C10F /* llformat.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llformat.h; sourceTree = "<group>"; }; | ||
265 | DA4D182B0B567ED70049C10F /* llerrorcontrol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = llerrorcontrol.h; sourceTree = "<group>"; }; | ||
266 | DA9C40460B540D8A00DD6F44 /* lllivefile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lllivefile.cpp; sourceTree = "<group>"; }; | ||
267 | DA9C40470B540D8A00DD6F44 /* lllivefile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lllivefile.h; sourceTree = "<group>"; }; | ||
255 | DAD1C4CA0AE2C78C0054574C /* stats.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stats.h; sourceTree = "<group>"; }; | 268 | DAD1C4CA0AE2C78C0054574C /* stats.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stats.h; sourceTree = "<group>"; }; |
256 | DAD1C4CB0AE2C78C0054574C /* stats.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = stats.cpp; sourceTree = "<group>"; }; | 269 | DAD1C4CB0AE2C78C0054574C /* stats.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = stats.cpp; sourceTree = "<group>"; }; |
257 | DAD1C4DC0AE2CA0C0054574C /* llcurl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = llcurl.h; sourceTree = "<group>"; }; | ||
258 | DAD1C4DD0AE2CA0C0054574C /* llcurl.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = llcurl.cpp; sourceTree = "<group>"; }; | ||
259 | FD15584C0A06BE2E00DE9AE5 /* io.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = io.cpp; sourceTree = "<group>"; }; | 270 | FD15584C0A06BE2E00DE9AE5 /* io.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = io.cpp; sourceTree = "<group>"; }; |
260 | FD1558500A06BEB000DE9AE5 /* llbuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llbuffer.cpp; sourceTree = "<group>"; }; | 271 | FD1558500A06BEB000DE9AE5 /* llbuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llbuffer.cpp; sourceTree = "<group>"; }; |
261 | FD1558510A06BEB000DE9AE5 /* llbuffer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llbuffer.h; sourceTree = "<group>"; }; | 272 | FD1558510A06BEB000DE9AE5 /* llbuffer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llbuffer.h; sourceTree = "<group>"; }; |
@@ -322,6 +333,11 @@ | |||
322 | FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llfasttimer.cpp; sourceTree = "<group>"; }; | 333 | FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llfasttimer.cpp; sourceTree = "<group>"; }; |
323 | FD155F600A08FD5900DE9AE5 /* llfasttimer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llfasttimer.h; sourceTree = "<group>"; }; | 334 | FD155F600A08FD5900DE9AE5 /* llfasttimer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llfasttimer.h; sourceTree = "<group>"; }; |
324 | FD155F660A08FD9100DE9AE5 /* message_string_table.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = message_string_table.cpp; sourceTree = "<group>"; }; | 335 | FD155F660A08FD9100DE9AE5 /* message_string_table.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = message_string_table.cpp; sourceTree = "<group>"; }; |
336 | FD23FEB70B4340F3007A29CA /* llhttpnode_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llhttpnode_tut.cpp; sourceTree = "<group>"; }; | ||
337 | FD23FEB80B4340F3007A29CA /* lluserrelations_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluserrelations_tut.cpp; sourceTree = "<group>"; }; | ||
338 | FD23FEBC0B43410C007A29CA /* lluserrelations.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluserrelations.cpp; sourceTree = "<group>"; }; | ||
339 | FD23FEBD0B43410C007A29CA /* lluserrelations.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lluserrelations.h; sourceTree = "<group>"; }; | ||
340 | FD23FEC50B4341E2007A29CA /* llerror_tut.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llerror_tut.cpp; sourceTree = "<group>"; }; | ||
325 | FD396CD80A1D3768005DCB1F /* lltut.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lltut.h; sourceTree = "<group>"; }; | 341 | FD396CD80A1D3768005DCB1F /* lltut.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lltut.h; sourceTree = "<group>"; }; |
326 | FD396CDC0A1D37DF005DCB1F /* lltut.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lltut.cpp; sourceTree = "<group>"; }; | 342 | FD396CDC0A1D37DF005DCB1F /* lltut.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = lltut.cpp; sourceTree = "<group>"; }; |
327 | FD506A0409FEB58900E297C2 /* llsdserialize.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llsdserialize.cpp; sourceTree = "<group>"; }; | 343 | FD506A0409FEB58900E297C2 /* llsdserialize.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llsdserialize.cpp; sourceTree = "<group>"; }; |
@@ -340,8 +356,6 @@ | |||
340 | FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lldate.cpp; sourceTree = "<group>"; }; | 356 | FD5DFA9009C1DF3E007E3F78 /* lldate.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lldate.cpp; sourceTree = "<group>"; }; |
341 | FD5DFA9209C1DF4E007E3F78 /* lluuid.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluuid.cpp; sourceTree = "<group>"; }; | 357 | FD5DFA9209C1DF4E007E3F78 /* lluuid.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluuid.cpp; sourceTree = "<group>"; }; |
342 | FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluri.cpp; sourceTree = "<group>"; }; | 358 | FD5DFA9709C1DFB7007E3F78 /* lluri.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = lluri.cpp; sourceTree = "<group>"; }; |
343 | FD5DFA9C09C1DFE2007E3F78 /* llerrorbuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llerrorbuffer.cpp; sourceTree = "<group>"; }; | ||
344 | FD5DFA9E09C1DFE2007E3F78 /* llerrorstream.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llerrorstream.cpp; sourceTree = "<group>"; }; | ||
345 | FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llmd5.cpp; sourceTree = "<group>"; }; | 359 | FD5DFAA509C1E01D007E3F78 /* llmd5.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llmd5.cpp; sourceTree = "<group>"; }; |
346 | FD5DFAA809C1E056007E3F78 /* llerror.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llerror.cpp; sourceTree = "<group>"; }; | 360 | FD5DFAA809C1E056007E3F78 /* llerror.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llerror.cpp; sourceTree = "<group>"; }; |
347 | FD5DFAAB09C1E09F007E3F78 /* llrand.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llrand.cpp; sourceTree = "<group>"; }; | 361 | FD5DFAAB09C1E09F007E3F78 /* llrand.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llrand.cpp; sourceTree = "<group>"; }; |
@@ -352,7 +366,6 @@ | |||
352 | FD7325790A0834080072A37B /* llapr.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llapr.h; sourceTree = "<group>"; }; | 366 | FD7325790A0834080072A37B /* llapr.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llapr.h; sourceTree = "<group>"; }; |
353 | FD73257A0A0834080072A37B /* lldate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lldate.h; sourceTree = "<group>"; }; | 367 | FD73257A0A0834080072A37B /* lldate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lldate.h; sourceTree = "<group>"; }; |
354 | FD73257B0A0834080072A37B /* llerror.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llerror.h; sourceTree = "<group>"; }; | 368 | FD73257B0A0834080072A37B /* llerror.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llerror.h; sourceTree = "<group>"; }; |
355 | FD73257C0A0834080072A37B /* llerrorbuffer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llerrorbuffer.h; sourceTree = "<group>"; }; | ||
356 | FD73257D0A0834080072A37B /* llstring.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llstring.h; sourceTree = "<group>"; }; | 369 | FD73257D0A0834080072A37B /* llstring.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llstring.h; sourceTree = "<group>"; }; |
357 | FD73257E0A0834080072A37B /* lltimer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lltimer.h; sourceTree = "<group>"; }; | 370 | FD73257E0A0834080072A37B /* lltimer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lltimer.h; sourceTree = "<group>"; }; |
358 | FD73257F0A0834080072A37B /* lluri.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lluri.h; sourceTree = "<group>"; }; | 371 | FD73257F0A0834080072A37B /* lluri.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = lluri.h; sourceTree = "<group>"; }; |
@@ -425,6 +438,8 @@ | |||
425 | FDBC10660AEEC3A600ED2E62 /* llpriqueuemap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llpriqueuemap.h; sourceTree = "<group>"; }; | 438 | FDBC10660AEEC3A600ED2E62 /* llpriqueuemap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llpriqueuemap.h; sourceTree = "<group>"; }; |
426 | FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llprocessor.cpp; sourceTree = "<group>"; }; | 439 | FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llprocessor.cpp; sourceTree = "<group>"; }; |
427 | FDCB2A660AF80D9000C44EBA /* llprocessor.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llprocessor.h; sourceTree = "<group>"; }; | 440 | FDCB2A660AF80D9000C44EBA /* llprocessor.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llprocessor.h; sourceTree = "<group>"; }; |
441 | FDE7AD520B7D047700C56FE0 /* llcurl.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llcurl.cpp; sourceTree = "<group>"; }; | ||
442 | FDE7AD530B7D047700C56FE0 /* llcurl.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llcurl.h; sourceTree = "<group>"; }; | ||
428 | FDF2E4180ADD7B620003B83E /* TestWebServer */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = TestWebServer; sourceTree = BUILT_PRODUCTS_DIR; }; | 443 | FDF2E4180ADD7B620003B83E /* TestWebServer */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = TestWebServer; sourceTree = BUILT_PRODUCTS_DIR; }; |
429 | FDF2E5580ADDBB7F0003B83E /* llhttpdelayeddata.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llhttpdelayeddata.cpp; sourceTree = "<group>"; }; | 444 | FDF2E5580ADDBB7F0003B83E /* llhttpdelayeddata.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = llhttpdelayeddata.cpp; sourceTree = "<group>"; }; |
430 | FDF2E5590ADDBB7F0003B83E /* llhttpdelayeddata.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llhttpdelayeddata.h; sourceTree = "<group>"; }; | 445 | FDF2E5590ADDBB7F0003B83E /* llhttpdelayeddata.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = llhttpdelayeddata.h; sourceTree = "<group>"; }; |
@@ -492,6 +507,9 @@ | |||
492 | 08FB7795FE84155DC02AAC07 /* test */ = { | 507 | 08FB7795FE84155DC02AAC07 /* test */ = { |
493 | isa = PBXGroup; | 508 | isa = PBXGroup; |
494 | children = ( | 509 | children = ( |
510 | FD23FEC50B4341E2007A29CA /* llerror_tut.cpp */, | ||
511 | FD23FEB70B4340F3007A29CA /* llhttpnode_tut.cpp */, | ||
512 | FD23FEB80B4340F3007A29CA /* lluserrelations_tut.cpp */, | ||
495 | DA01B1F10ADE831200A44198 /* testwebclient */, | 513 | DA01B1F10ADE831200A44198 /* testwebclient */, |
496 | FDF2E5600ADDBB900003B83E /* testwebserver */, | 514 | FDF2E5600ADDBB900003B83E /* testwebserver */, |
497 | 91469E830B44870B0009E8F9 /* llmime_tut.cpp */, | 515 | 91469E830B44870B0009E8F9 /* llmime_tut.cpp */, |
@@ -532,8 +550,6 @@ | |||
532 | DA01B2040ADE839D00A44198 /* testwebclient.cpp */, | 550 | DA01B2040ADE839D00A44198 /* testwebclient.cpp */, |
533 | DAD1C4CA0AE2C78C0054574C /* stats.h */, | 551 | DAD1C4CA0AE2C78C0054574C /* stats.h */, |
534 | DAD1C4CB0AE2C78C0054574C /* stats.cpp */, | 552 | DAD1C4CB0AE2C78C0054574C /* stats.cpp */, |
535 | DAD1C4DC0AE2CA0C0054574C /* llcurl.h */, | ||
536 | DAD1C4DD0AE2CA0C0054574C /* llcurl.cpp */, | ||
537 | ); | 553 | ); |
538 | path = testwebclient; | 554 | path = testwebclient; |
539 | sourceTree = "<group>"; | 555 | sourceTree = "<group>"; |
@@ -541,6 +557,8 @@ | |||
541 | FD15584F0A06BE4100DE9AE5 /* llmessage */ = { | 557 | FD15584F0A06BE4100DE9AE5 /* llmessage */ = { |
542 | isa = PBXGroup; | 558 | isa = PBXGroup; |
543 | children = ( | 559 | children = ( |
560 | FDE7AD520B7D047700C56FE0 /* llcurl.cpp */, | ||
561 | FDE7AD530B7D047700C56FE0 /* llcurl.h */, | ||
544 | 91469E7F0B4486F20009E8F9 /* llmime.cpp */, | 562 | 91469E7F0B4486F20009E8F9 /* llmime.cpp */, |
545 | 91469E800B4486F20009E8F9 /* llmime.h */, | 563 | 91469E800B4486F20009E8F9 /* llmime.h */, |
546 | FDFAD41F0AFFFCC30048A0C7 /* llhttpnode.cpp */, | 564 | FDFAD41F0AFFFCC30048A0C7 /* llhttpnode.cpp */, |
@@ -641,6 +659,10 @@ | |||
641 | FD5DF88009C0A17D007E3F78 /* llcommon */ = { | 659 | FD5DF88009C0A17D007E3F78 /* llcommon */ = { |
642 | isa = PBXGroup; | 660 | isa = PBXGroup; |
643 | children = ( | 661 | children = ( |
662 | DA4D18150B567E0D0049C10F /* llformat.cpp */, | ||
663 | DA4D18160B567E0D0049C10F /* llformat.h */, | ||
664 | DA9C40460B540D8A00DD6F44 /* lllivefile.cpp */, | ||
665 | DA9C40470B540D8A00DD6F44 /* lllivefile.h */, | ||
644 | FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */, | 666 | FDCB2A650AF80D9000C44EBA /* llprocessor.cpp */, |
645 | FDCB2A660AF80D9000C44EBA /* llprocessor.h */, | 667 | FDCB2A660AF80D9000C44EBA /* llprocessor.h */, |
646 | FDBC10660AEEC3A600ED2E62 /* llpriqueuemap.h */, | 668 | FDBC10660AEEC3A600ED2E62 /* llpriqueuemap.h */, |
@@ -663,9 +685,6 @@ | |||
663 | FD73257A0A0834080072A37B /* lldate.h */, | 685 | FD73257A0A0834080072A37B /* lldate.h */, |
664 | FD5DFAA809C1E056007E3F78 /* llerror.cpp */, | 686 | FD5DFAA809C1E056007E3F78 /* llerror.cpp */, |
665 | FD73257B0A0834080072A37B /* llerror.h */, | 687 | FD73257B0A0834080072A37B /* llerror.h */, |
666 | FD5DFA9C09C1DFE2007E3F78 /* llerrorbuffer.cpp */, | ||
667 | FD73257C0A0834080072A37B /* llerrorbuffer.h */, | ||
668 | FD5DFA9E09C1DFE2007E3F78 /* llerrorstream.cpp */, | ||
669 | FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */, | 688 | FD155F5F0A08FD5900DE9AE5 /* llfasttimer.cpp */, |
670 | FD155F600A08FD5900DE9AE5 /* llfasttimer.h */, | 689 | FD155F600A08FD5900DE9AE5 /* llfasttimer.h */, |
671 | 389CFB450A0B69C700EE2094 /* llfile.cpp */, | 690 | 389CFB450A0B69C700EE2094 /* llfile.cpp */, |
@@ -702,6 +721,7 @@ | |||
702 | 38A8BF690A18C38800814862 /* reflective.h */, | 721 | 38A8BF690A18C38800814862 /* reflective.h */, |
703 | FD5DFAB809C1E13A007E3F78 /* u64.cpp */, | 722 | FD5DFAB809C1E13A007E3F78 /* u64.cpp */, |
704 | FD7325800A0834080072A37B /* u64.h */, | 723 | FD7325800A0834080072A37B /* u64.h */, |
724 | DA4D182B0B567ED70049C10F /* llerrorcontrol.h */, | ||
705 | ); | 725 | ); |
706 | name = llcommon; | 726 | name = llcommon; |
707 | path = ../llcommon; | 727 | path = ../llcommon; |
@@ -743,6 +763,8 @@ | |||
743 | FD73259C0A08E8520072A37B /* llinventory */ = { | 763 | FD73259C0A08E8520072A37B /* llinventory */ = { |
744 | isa = PBXGroup; | 764 | isa = PBXGroup; |
745 | children = ( | 765 | children = ( |
766 | FD23FEBC0B43410C007A29CA /* lluserrelations.cpp */, | ||
767 | FD23FEBD0B43410C007A29CA /* lluserrelations.h */, | ||
746 | FD73259D0A08E8A00072A37B /* llinventory.cpp */, | 768 | FD73259D0A08E8A00072A37B /* llinventory.cpp */, |
747 | FD73259E0A08E8A00072A37B /* llinventory.h */, | 769 | FD73259E0A08E8A00072A37B /* llinventory.h */, |
748 | FD7325AA0A08E9330072A37B /* llpermissions.cpp */, | 770 | FD7325AA0A08E9330072A37B /* llpermissions.cpp */, |
@@ -894,8 +916,6 @@ | |||
894 | FD5DFA9109C1DF3E007E3F78 /* lldate.cpp in Sources */, | 916 | FD5DFA9109C1DF3E007E3F78 /* lldate.cpp in Sources */, |
895 | FD5DFA9309C1DF4E007E3F78 /* lluuid.cpp in Sources */, | 917 | FD5DFA9309C1DF4E007E3F78 /* lluuid.cpp in Sources */, |
896 | FD5DFA9909C1DFB7007E3F78 /* lluri.cpp in Sources */, | 918 | FD5DFA9909C1DFB7007E3F78 /* lluri.cpp in Sources */, |
897 | FD5DFAA009C1DFE2007E3F78 /* llerrorbuffer.cpp in Sources */, | ||
898 | FD5DFAA209C1DFE2007E3F78 /* llerrorstream.cpp in Sources */, | ||
899 | FD5DFAA609C1E01D007E3F78 /* llmd5.cpp in Sources */, | 919 | FD5DFAA609C1E01D007E3F78 /* llmd5.cpp in Sources */, |
900 | FD5DFAA909C1E056007E3F78 /* llerror.cpp in Sources */, | 920 | FD5DFAA909C1E056007E3F78 /* llerror.cpp in Sources */, |
901 | FD5DFAAC09C1E09F007E3F78 /* llrand.cpp in Sources */, | 921 | FD5DFAAC09C1E09F007E3F78 /* llrand.cpp in Sources */, |
@@ -993,6 +1013,12 @@ | |||
993 | 91469E810B4486F20009E8F9 /* llmime.cpp in Sources */, | 1013 | 91469E810B4486F20009E8F9 /* llmime.cpp in Sources */, |
994 | 91469E840B44870B0009E8F9 /* llmime_tut.cpp in Sources */, | 1014 | 91469E840B44870B0009E8F9 /* llmime_tut.cpp in Sources */, |
995 | 91469E8D0B4489420009E8F9 /* llquaternion.cpp in Sources */, | 1015 | 91469E8D0B4489420009E8F9 /* llquaternion.cpp in Sources */, |
1016 | FD23FEB90B4340F3007A29CA /* llhttpnode_tut.cpp in Sources */, | ||
1017 | FD23FEBA0B4340F3007A29CA /* lluserrelations_tut.cpp in Sources */, | ||
1018 | FD23FEBE0B43410C007A29CA /* lluserrelations.cpp in Sources */, | ||
1019 | FD23FEC60B4341E2007A29CA /* llerror_tut.cpp in Sources */, | ||
1020 | DA9C40480B540D8A00DD6F44 /* lllivefile.cpp in Sources */, | ||
1021 | DA4D18170B567E0D0049C10F /* llformat.cpp in Sources */, | ||
996 | ); | 1022 | ); |
997 | runOnlyForDeploymentPostprocessing = 0; | 1023 | runOnlyForDeploymentPostprocessing = 0; |
998 | }; | 1024 | }; |
@@ -1001,15 +1027,12 @@ | |||
1001 | buildActionMask = 2147483647; | 1027 | buildActionMask = 2147483647; |
1002 | files = ( | 1028 | files = ( |
1003 | DAD1C4CC0AE2C78C0054574C /* stats.cpp in Sources */, | 1029 | DAD1C4CC0AE2C78C0054574C /* stats.cpp in Sources */, |
1004 | DAD1C4DE0AE2CA0C0054574C /* llcurl.cpp in Sources */, | ||
1005 | FDBC106D0AEEC3DA00ED2E62 /* llsd.cpp in Sources */, | 1030 | FDBC106D0AEEC3DA00ED2E62 /* llsd.cpp in Sources */, |
1006 | FDBC106F0AEEC3E900ED2E62 /* lluuid.cpp in Sources */, | 1031 | FDBC106F0AEEC3E900ED2E62 /* lluuid.cpp in Sources */, |
1007 | FDBC10710AEEC3F800ED2E62 /* llsdserialize.cpp in Sources */, | 1032 | FDBC10710AEEC3F800ED2E62 /* llsdserialize.cpp in Sources */, |
1008 | FDBC10720AEEC3F900ED2E62 /* llsdserialize_xml.cpp in Sources */, | 1033 | FDBC10720AEEC3F900ED2E62 /* llsdserialize_xml.cpp in Sources */, |
1009 | FDBC10750AEEC41600ED2E62 /* lldate.cpp in Sources */, | 1034 | FDBC10750AEEC41600ED2E62 /* lldate.cpp in Sources */, |
1010 | FDBC10760AEEC41B00ED2E62 /* llmd5.cpp in Sources */, | 1035 | FDBC10760AEEC41B00ED2E62 /* llmd5.cpp in Sources */, |
1011 | FDBC10790AEEC42B00ED2E62 /* llerrorstream.cpp in Sources */, | ||
1012 | FDBC107A0AEEC42C00ED2E62 /* llerrorbuffer.cpp in Sources */, | ||
1013 | FDBC107B0AEEC43200ED2E62 /* lluri.cpp in Sources */, | 1036 | FDBC107B0AEEC43200ED2E62 /* lluri.cpp in Sources */, |
1014 | FDBC107E0AEEC45100ED2E62 /* lltimer.cpp in Sources */, | 1037 | FDBC107E0AEEC45100ED2E62 /* lltimer.cpp in Sources */, |
1015 | FDBC107F0AEEC45400ED2E62 /* llfasttimer.cpp in Sources */, | 1038 | FDBC107F0AEEC45400ED2E62 /* llfasttimer.cpp in Sources */, |
@@ -1031,6 +1054,7 @@ | |||
1031 | FDBC10A90AEEC65700ED2E62 /* llstreamtools.cpp in Sources */, | 1054 | FDBC10A90AEEC65700ED2E62 /* llstreamtools.cpp in Sources */, |
1032 | FDBC10AB0AEEC66100ED2E62 /* testwebclient.cpp in Sources */, | 1055 | FDBC10AB0AEEC66100ED2E62 /* testwebclient.cpp in Sources */, |
1033 | FDBC10AD0AEEC67700ED2E62 /* llframetimer.cpp in Sources */, | 1056 | FDBC10AD0AEEC67700ED2E62 /* llframetimer.cpp in Sources */, |
1057 | FDE7AD540B7D047700C56FE0 /* llcurl.cpp in Sources */, | ||
1034 | ); | 1058 | ); |
1035 | runOnlyForDeploymentPostprocessing = 0; | 1059 | runOnlyForDeploymentPostprocessing = 0; |
1036 | }; | 1060 | }; |
diff --git a/linden/indra/test/blowfish.1.bin b/linden/indra/test/blowfish.1.bin new file mode 100644 index 0000000..61286e4 --- /dev/null +++ b/linden/indra/test/blowfish.1.bin | |||
@@ -0,0 +1 @@ | |||
.A„Ä3ŒLÜE ``òøÝKÛ@¼ûÇ;M[ÚBë·ø„>ËÊC—' \ No newline at end of file | |||
diff --git a/linden/indra/test/blowfish.2.bin b/linden/indra/test/blowfish.2.bin new file mode 100644 index 0000000..ef72d96 --- /dev/null +++ b/linden/indra/test/blowfish.2.bin | |||
Binary files differ | |||
diff --git a/linden/indra/test/blowfish.digits.txt b/linden/indra/test/blowfish.digits.txt new file mode 100644 index 0000000..fce1fed --- /dev/null +++ b/linden/indra/test/blowfish.digits.txt | |||
@@ -0,0 +1 @@ | |||
01234567890123456789012345678901234 | |||
diff --git a/linden/indra/test/blowfish.pl b/linden/indra/test/blowfish.pl new file mode 100755 index 0000000..7940d87 --- /dev/null +++ b/linden/indra/test/blowfish.pl | |||
@@ -0,0 +1,74 @@ | |||
1 | #!/usr/bin/perl | ||
2 | use strict; | ||
3 | use warnings; | ||
4 | |||
5 | # *TODO: specify test count here | ||
6 | use Test::More qw(no_plan); | ||
7 | |||
8 | use Crypt::CBC; | ||
9 | use MIME::Base64; | ||
10 | |||
11 | my $init_vector = "\x00" x 8; | ||
12 | # my $key = pack("H*", "ef5a8376eb0c99fe0dafa487d15bec19cae63d1e25fe31d8d92f7ab0398246d70ee733108e47360e16359654571cf5bab6c3375b42cee4fa"); | ||
13 | # my $key = "d263eb8a78034e40"; | ||
14 | #"8d082918aa369174"; | ||
15 | my $key = "\x00" x 16; | ||
16 | |||
17 | my $cipher = Crypt::CBC->new( { cipher => 'Blowfish', | ||
18 | regenerate_key => 0, | ||
19 | key => $key, | ||
20 | iv => $init_vector, | ||
21 | header => 'none', | ||
22 | prepend_iv => 0, | ||
23 | keysize => 16 } ); | ||
24 | |||
25 | #my $blocks = $cipher->blocksize(); | ||
26 | #print "blocksize $blocks\n"; | ||
27 | |||
28 | my $len; | ||
29 | my $input = "01234567890123456789012345678901234\n"; | ||
30 | #my $input = "a whale of a tale I tell you lad, a whale of a tale for me, a whale of a tale and the fiddlers three"; | ||
31 | $len = length($input); | ||
32 | is ($len, 36, "input length"); | ||
33 | |||
34 | $len = length($key); | ||
35 | is ($len, 16, "key length"); | ||
36 | |||
37 | |||
38 | my $encrypted = $cipher->encrypt($input); | ||
39 | is (length($encrypted), 40, "encrypted length"); | ||
40 | |||
41 | open(FH, "blowfish.1.bin"); | ||
42 | my $bin = scalar <FH>; | ||
43 | is ($encrypted, $bin, "matches openssl"); | ||
44 | close(FH); | ||
45 | |||
46 | my $base64 = encode_base64($encrypted); | ||
47 | is ($base64, "LkGExDOMTNxFIGBg8gP43UvbQLz7xztNWwYF2kLrtwT4hD7LykOXJw==\n", | ||
48 | "base64 output"); | ||
49 | |||
50 | my $unbase64 = decode_base64($base64); | ||
51 | is( $encrypted, $unbase64, "reverse base64" ); | ||
52 | |||
53 | my $output = $cipher->decrypt($unbase64); | ||
54 | is ($input, $output, "reverse encrypt"); | ||
55 | |||
56 | $key = pack("H[32]", "526a1e07a19dbaed84c4ff08a488d15e"); | ||
57 | $cipher = Crypt::CBC->new( { cipher => 'Blowfish', | ||
58 | regenerate_key => 0, | ||
59 | key => $key, | ||
60 | iv => $init_vector, | ||
61 | header => 'none', | ||
62 | prepend_iv => 0, | ||
63 | keysize => 16 } ); | ||
64 | $encrypted = $cipher->encrypt($input); | ||
65 | is (length($encrypted), 40, "uuid encrypted length"); | ||
66 | $output = $cipher->decrypt($encrypted); | ||
67 | is ($input, $output, "uuid reverse encrypt"); | ||
68 | |||
69 | open(FH, "blowfish.2.bin"); | ||
70 | $bin = scalar <FH>; | ||
71 | close(FH); | ||
72 | is( $encrypted, $bin, "uuid matches openssl" ); | ||
73 | |||
74 | print encode_base64($encrypted); | ||
diff --git a/linden/indra/test/common.cpp b/linden/indra/test/common.cpp index 1be0931..97ff21c 100644 --- a/linden/indra/test/common.cpp +++ b/linden/indra/test/common.cpp | |||
@@ -109,7 +109,7 @@ namespace tut | |||
109 | // gen up a starting point | 109 | // gen up a starting point |
110 | typedef std::vector<U8> buf_t; | 110 | typedef std::vector<U8> buf_t; |
111 | buf_t source; | 111 | buf_t source; |
112 | srand(i); | 112 | srand(i); /* Flawfinder: ignore */ |
113 | S32 size = rand() % 1000 + 10; | 113 | S32 size = rand() % 1000 + 10; |
114 | std::generate_n( | 114 | std::generate_n( |
115 | std::back_insert_iterator<buf_t>(source), | 115 | std::back_insert_iterator<buf_t>(source), |
@@ -157,7 +157,7 @@ namespace tut | |||
157 | // gen up a starting point | 157 | // gen up a starting point |
158 | typedef std::vector<U8> buf_t; | 158 | typedef std::vector<U8> buf_t; |
159 | buf_t source; | 159 | buf_t source; |
160 | srand(666 + i); | 160 | srand(666 + i); /* Flawfinder: ignore */ |
161 | S32 size = rand() % 1000 + 10; | 161 | S32 size = rand() % 1000 + 10; |
162 | std::generate_n( | 162 | std::generate_n( |
163 | std::back_insert_iterator<buf_t>(source), | 163 | std::back_insert_iterator<buf_t>(source), |
@@ -307,7 +307,7 @@ namespace tut | |||
307 | { | 307 | { |
308 | // gen up a starting point | 308 | // gen up a starting point |
309 | std::string expected; | 309 | std::string expected; |
310 | srand(1337 + i); | 310 | srand(1337 + i); /* Flawfinder: ignore */ |
311 | S32 size = rand() % 30 + 5; | 311 | S32 size = rand() % 30 + 5; |
312 | std::generate_n( | 312 | std::generate_n( |
313 | std::back_insert_iterator<std::string>(expected), | 313 | std::back_insert_iterator<std::string>(expected), |
@@ -436,7 +436,7 @@ namespace tut | |||
436 | void mem_object::test<1>() | 436 | void mem_object::test<1>() |
437 | { | 437 | { |
438 | const char HELLO_WORLD[] = "hello world"; | 438 | const char HELLO_WORLD[] = "hello world"; |
439 | LLMemoryStream mem((U8*)&HELLO_WORLD[0], strlen(HELLO_WORLD)); | 439 | LLMemoryStream mem((U8*)&HELLO_WORLD[0], strlen(HELLO_WORLD)); /* Flawfinder: ignore */ |
440 | std::string hello; | 440 | std::string hello; |
441 | std::string world; | 441 | std::string world; |
442 | mem >> hello >> world; | 442 | mem >> hello >> world; |
diff --git a/linden/indra/test/files.lst b/linden/indra/test/files.lst index 0f99ce9..77ce9f4 100644 --- a/linden/indra/test/files.lst +++ b/linden/indra/test/files.lst | |||
@@ -2,6 +2,9 @@ test/common.cpp | |||
2 | test/inventory.cpp | 2 | test/inventory.cpp |
3 | test/io.cpp | 3 | test/io.cpp |
4 | test/llapp_tut.cpp | 4 | test/llapp_tut.cpp |
5 | test/llbase64_tut.cpp | ||
6 | test/llblowfish_tut.cpp | ||
7 | test/llerror_tut.cpp | ||
5 | test/llhttpclient_tut.cpp | 8 | test/llhttpclient_tut.cpp |
6 | test/llhttpnode_tut.cpp | 9 | test/llhttpnode_tut.cpp |
7 | test/lliohttpserver_tut.cpp | 10 | test/lliohttpserver_tut.cpp |
diff --git a/linden/indra/test/io.cpp b/linden/indra/test/io.cpp index 2f6ba09..a86711a 100644 --- a/linden/indra/test/io.cpp +++ b/linden/indra/test/io.cpp | |||
@@ -77,7 +77,7 @@ namespace tut | |||
77 | void buffer_object::test<2>() | 77 | void buffer_object::test<2>() |
78 | { | 78 | { |
79 | const char HELLO_WORLD[] = "hello world"; | 79 | const char HELLO_WORLD[] = "hello world"; |
80 | const S32 str_len = strlen(HELLO_WORLD); | 80 | const S32 str_len = strlen(HELLO_WORLD); /* Flawfinder: ignore */ |
81 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 81 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
82 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); | 82 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); |
83 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); | 83 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); |
@@ -99,7 +99,7 @@ namespace tut | |||
99 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 99 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
100 | mBuffer.append(ch.in(), (U8*)ONE, 3); | 100 | mBuffer.append(ch.in(), (U8*)ONE, 3); |
101 | mBuffer.append(ch.in(), (U8*)TWO, 3); | 101 | mBuffer.append(ch.in(), (U8*)TWO, 3); |
102 | char buffer[255]; | 102 | char buffer[255]; /* Flawfinder: ignore */ |
103 | S32 len = 6; | 103 | S32 len = 6; |
104 | mBuffer.readAfter(ch.in(), NULL, (U8*)buffer, len); | 104 | mBuffer.readAfter(ch.in(), NULL, (U8*)buffer, len); |
105 | ensure_equals(len, 6); | 105 | ensure_equals(len, 6); |
@@ -118,7 +118,7 @@ namespace tut | |||
118 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 118 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
119 | mBuffer.append(ch.in(), (U8*)TWO, 3); | 119 | mBuffer.append(ch.in(), (U8*)TWO, 3); |
120 | mBuffer.prepend(ch.in(), (U8*)ONE, 3); | 120 | mBuffer.prepend(ch.in(), (U8*)ONE, 3); |
121 | char buffer[255]; | 121 | char buffer[255]; /* Flawfinder: ignore */ |
122 | S32 len = 6; | 122 | S32 len = 6; |
123 | mBuffer.readAfter(ch.in(), NULL, (U8*)buffer, len); | 123 | mBuffer.readAfter(ch.in(), NULL, (U8*)buffer, len); |
124 | ensure_equals(len, 6); | 124 | ensure_equals(len, 6); |
@@ -136,7 +136,7 @@ namespace tut | |||
136 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 136 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
137 | mBuffer.append(ch.in(), (U8*)TWO, 3); | 137 | mBuffer.append(ch.in(), (U8*)TWO, 3); |
138 | mBuffer.prepend(ch.in(), (U8*)ONE, 3); | 138 | mBuffer.prepend(ch.in(), (U8*)ONE, 3); |
139 | char buffer[255]; | 139 | char buffer[255]; /* Flawfinder: ignore */ |
140 | S32 len = 5; | 140 | S32 len = 5; |
141 | LLBufferArray::segment_iterator_t it = mBuffer.beginSegment(); | 141 | LLBufferArray::segment_iterator_t it = mBuffer.beginSegment(); |
142 | U8* addr = (*it).data(); | 142 | U8* addr = (*it).data(); |
@@ -163,7 +163,7 @@ namespace tut | |||
163 | header << "ContentLength: " << count << "\r\n\r\n"; | 163 | header << "ContentLength: " << count << "\r\n\r\n"; |
164 | std::string head(header.str()); | 164 | std::string head(header.str()); |
165 | mBuffer.prepend(ch.out(), (U8*)head.c_str(), head.length()); | 165 | mBuffer.prepend(ch.out(), (U8*)head.c_str(), head.length()); |
166 | char buffer[1024]; | 166 | char buffer[1024]; /* Flawfinder: ignore */ |
167 | S32 len = response.size() + head.length(); | 167 | S32 len = response.size() + head.length(); |
168 | ensure_equals("same length", len, (S32)expected.str().length()); | 168 | ensure_equals("same length", len, (S32)expected.str().length()); |
169 | mBuffer.readAfter(ch.out(), NULL, (U8*)buffer, len); | 169 | mBuffer.readAfter(ch.out(), NULL, (U8*)buffer, len); |
@@ -228,11 +228,11 @@ namespace tut | |||
228 | delete[] temp; | 228 | delete[] temp; |
229 | } | 229 | } |
230 | 230 | ||
231 | /* | 231 | #if 0 |
232 | template<> template<> | 232 | template<> template<> |
233 | void buffer_object::test<9>() | 233 | void buffer_object::test<9>() |
234 | { | 234 | { |
235 | char buffer[1024]; | 235 | char buffer[1024]; /* Flawfinder: ignore */ |
236 | S32 size = sprintf(buffer, | 236 | S32 size = sprintf(buffer, |
237 | "%d|%d|%s|%s|%s|%s|%s|%x|%x|%x|%x|%x|%s|%s|%d|%d|%x", | 237 | "%d|%d|%s|%s|%s|%s|%s|%x|%x|%x|%x|%x|%s|%s|%d|%d|%x", |
238 | 7, | 238 | 7, |
@@ -263,7 +263,7 @@ namespace tut | |||
263 | ensure_equals("Buffer sizes",size,(S32)post_size); | 263 | ensure_equals("Buffer sizes",size,(S32)post_size); |
264 | ensure("Buffer content",!strcmp(buffer,post_buffer)); | 264 | ensure("Buffer content",!strcmp(buffer,post_buffer)); |
265 | } | 265 | } |
266 | */ | 266 | #endif |
267 | 267 | ||
268 | /* | 268 | /* |
269 | template<> template<> | 269 | template<> template<> |
@@ -287,7 +287,7 @@ namespace tut | |||
287 | void bas_object::test<1>() | 287 | void bas_object::test<1>() |
288 | { | 288 | { |
289 | const char HELLO_WORLD[] = "hello world"; | 289 | const char HELLO_WORLD[] = "hello world"; |
290 | const S32 str_len = strlen(HELLO_WORLD); | 290 | const S32 str_len = strlen(HELLO_WORLD); /* Flawfinder: ignore */ |
291 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 291 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
292 | LLBufferStream str(ch, &mBuffer); | 292 | LLBufferStream str(ch, &mBuffer); |
293 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); | 293 | mBuffer.append(ch.in(), (U8*)HELLO_WORLD, str_len); |
@@ -425,7 +425,7 @@ namespace tut | |||
425 | ostr << ") "; | 425 | ostr << ") "; |
426 | bstr.flush(); | 426 | bstr.flush(); |
427 | const S32 BUF_LEN = 512; | 427 | const S32 BUF_LEN = 512; |
428 | char buf[BUF_LEN]; | 428 | char buf[BUF_LEN]; /* Flawfinder: ignore */ |
429 | S32 actual_len = BUF_LEN; | 429 | S32 actual_len = BUF_LEN; |
430 | (void) mBuffer.readAfter(ch.out(), NULL, (U8*)buf, actual_len); | 430 | (void) mBuffer.readAfter(ch.out(), NULL, (U8*)buf, actual_len); |
431 | buf[actual_len] = '\0'; | 431 | buf[actual_len] = '\0'; |
@@ -479,7 +479,7 @@ namespace tut | |||
479 | ++total_size; | 479 | ++total_size; |
480 | } | 480 | } |
481 | need_comma = true; | 481 | need_comma = true; |
482 | srand(69 + i); | 482 | srand(69 + i); /* Flawfinder: ignore */ |
483 | S32 size = rand() % 1000 + 1000; | 483 | S32 size = rand() % 1000 + 1000; |
484 | std::generate_n( | 484 | std::generate_n( |
485 | std::back_insert_iterator<buf_t>(source), | 485 | std::back_insert_iterator<buf_t>(source), |
@@ -545,7 +545,7 @@ namespace tut | |||
545 | need_comma = true; | 545 | need_comma = true; |
546 | ostr << "'" << i << "':"; | 546 | ostr << "'" << i << "':"; |
547 | total_size += 7; | 547 | total_size += 7; |
548 | srand(69 + i); | 548 | srand(69 + i); /* Flawfinder: ignore */ |
549 | S32 size = rand() % 1000 + 1000; | 549 | S32 size = rand() % 1000 + 1000; |
550 | std::generate_n( | 550 | std::generate_n( |
551 | std::back_insert_iterator<buf_t>(source), | 551 | std::back_insert_iterator<buf_t>(source), |
@@ -601,7 +601,7 @@ namespace tut | |||
601 | "'circuit_code': i124,'group_id': '8615c885-9cf0-bf0a-6e40-0c11462aa652','limited_to_estate': i1,'look_at': [ i0, i0, i0]," | 601 | "'circuit_code': i124,'group_id': '8615c885-9cf0-bf0a-6e40-0c11462aa652','limited_to_estate': i1,'look_at': [ i0, i0, i0]," |
602 | "'agent_id': '0e346d8b-4433-4d66-a6b0-fd37083abc4c','first_name': 'Kelly','start': 'url'}]}"; | 602 | "'agent_id': '0e346d8b-4433-4d66-a6b0-fd37083abc4c','first_name': 'Kelly','start': 'url'}]}"; |
603 | LLChannelDescriptors ch = mBuffer.nextChannel(); | 603 | LLChannelDescriptors ch = mBuffer.nextChannel(); |
604 | mBuffer.append(ch.out(), (U8*)LOGIN_STREAM, strlen(LOGIN_STREAM)); | 604 | mBuffer.append(ch.out(), (U8*)LOGIN_STREAM, strlen(LOGIN_STREAM)); /* Flawfinder: ignore */ |
605 | ch = mBuffer.nextChannel(); | 605 | ch = mBuffer.nextChannel(); |
606 | LLBufferStream istr(ch, &mBuffer); | 606 | LLBufferStream istr(ch, &mBuffer); |
607 | LLSD data; | 607 | LLSD data; |
@@ -1119,7 +1119,7 @@ namespace tut | |||
1119 | stream << "{'task_id':ucc706f2d-0b68-68f8-11a4-f1043ff35ca0}\n{\n\tname\tObject|\n\tpermissions 0\n}"; | 1119 | stream << "{'task_id':ucc706f2d-0b68-68f8-11a4-f1043ff35ca0}\n{\n\tname\tObject|\n\tpermissions 0\n}"; |
1120 | std::vector<U8> expected_binary; | 1120 | std::vector<U8> expected_binary; |
1121 | expected_binary.resize(stream.str().size()); | 1121 | expected_binary.resize(stream.str().size()); |
1122 | memcpy(&expected_binary[0], stream.str().c_str(), stream.str().size()); | 1122 | memcpy(&expected_binary[0], stream.str().c_str(), stream.str().size()); /* Flawfinder: ignore */ |
1123 | stream.str(""); | 1123 | stream.str(""); |
1124 | stream << "[{'uri':'" << uri << "'}, {'version':i1}, " | 1124 | stream << "[{'uri':'" << uri << "'}, {'version':i1}, " |
1125 | << "{'agent_id':'3c115e51-04f4-523c-9fa6-98aff1034730', 'session_id':'2c585cec-038c-40b0-b42e-a25ebab4d132', 'circuit_code':i1075, 'start':'region', 'limited_to_estate':i1 'first_name':'Phoenix', 'last_name':'Linden', 'group_title':'', 'group_id':u00000000-0000-0000-0000-000000000000, 'position':[r70.9247,r254.378,r38.7304], 'look_at':[r-0.043753,r-0.999042,r0], 'granters':[ua2e76fcd-9360-4f6d-a924-000000000003], 'texture_data':['5e481e8a-58a6-fc34-6e61-c7a36095c07f', 'c39675f5-ca90-a304-bb31-42cdb803a132', '5c989edf-88d1-b2ac-b00b-5ed4bab8e368', '6522e74d-1660-4e7f-b601-6f48c1659a77', '7ca39b4c-bd19-4699-aff7-f93fd03d3e7b', '41c58177-5eb6-5aeb-029d-bc4093f3c130', '97b75473-8b93-9b25-2a11-035b9ae93195', '1c2d8d9b-90eb-89d4-dea8-c1ed83990614', '69ec543f-e27b-c07c-9094-a8be6300f274', 'c9f8b80f-c629-4633-04ee-c566ce9fea4b', '989cddba-7ab6-01ed-67aa-74accd2a2a65', '45e319b2-6a8c-fa5c-895b-1a7149b88aef', '5748decc-f629-461c-9a36-a35a221fe21f', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', '685fbe10-ab40-f065-0aec-726cc6dfd7a1', '406f98fd-9c89-1d52-5f39-e67d508c5ee5', '685fbe10-ab40-f065-0aec-726cc6dfd7a1', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97'], " | 1125 | << "{'agent_id':'3c115e51-04f4-523c-9fa6-98aff1034730', 'session_id':'2c585cec-038c-40b0-b42e-a25ebab4d132', 'circuit_code':i1075, 'start':'region', 'limited_to_estate':i1 'first_name':'Phoenix', 'last_name':'Linden', 'group_title':'', 'group_id':u00000000-0000-0000-0000-000000000000, 'position':[r70.9247,r254.378,r38.7304], 'look_at':[r-0.043753,r-0.999042,r0], 'granters':[ua2e76fcd-9360-4f6d-a924-000000000003], 'texture_data':['5e481e8a-58a6-fc34-6e61-c7a36095c07f', 'c39675f5-ca90-a304-bb31-42cdb803a132', '5c989edf-88d1-b2ac-b00b-5ed4bab8e368', '6522e74d-1660-4e7f-b601-6f48c1659a77', '7ca39b4c-bd19-4699-aff7-f93fd03d3e7b', '41c58177-5eb6-5aeb-029d-bc4093f3c130', '97b75473-8b93-9b25-2a11-035b9ae93195', '1c2d8d9b-90eb-89d4-dea8-c1ed83990614', '69ec543f-e27b-c07c-9094-a8be6300f274', 'c9f8b80f-c629-4633-04ee-c566ce9fea4b', '989cddba-7ab6-01ed-67aa-74accd2a2a65', '45e319b2-6a8c-fa5c-895b-1a7149b88aef', '5748decc-f629-461c-9a36-a35a221fe21f', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', '685fbe10-ab40-f065-0aec-726cc6dfd7a1', '406f98fd-9c89-1d52-5f39-e67d508c5ee5', '685fbe10-ab40-f065-0aec-726cc6dfd7a1', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97', 'c228d1cf-4b5d-4ba8-84f4-899a0796aa97'], " |
@@ -1213,7 +1213,7 @@ namespace tut | |||
1213 | tmp_str << "{'task_id':ucc706f2d-0b68-68f8-11a4-f1043ff35ca0}\n{\n\tname\tObject|\n\tpermissions 0\n}"; | 1213 | tmp_str << "{'task_id':ucc706f2d-0b68-68f8-11a4-f1043ff35ca0}\n{\n\tname\tObject|\n\tpermissions 0\n}"; |
1214 | std::vector<U8> expected_binary; | 1214 | std::vector<U8> expected_binary; |
1215 | expected_binary.resize(tmp_str.str().size()); | 1215 | expected_binary.resize(tmp_str.str().size()); |
1216 | memcpy( | 1216 | memcpy( /* Flawfinder: ignore */ |
1217 | &expected_binary[0], | 1217 | &expected_binary[0], |
1218 | tmp_str.str().c_str(), | 1218 | tmp_str.str().c_str(), |
1219 | tmp_str.str().size()); | 1219 | tmp_str.str().size()); |
diff --git a/linden/indra/test/llapp_tut.cpp b/linden/indra/test/llapp_tut.cpp index a238cb3..3223f91 100644 --- a/linden/indra/test/llapp_tut.cpp +++ b/linden/indra/test/llapp_tut.cpp | |||
@@ -150,4 +150,17 @@ namespace tut | |||
150 | bool ok = mApp->parseCommandOptions(ARGC, ARGV); | 150 | bool ok = mApp->parseCommandOptions(ARGC, ARGV); |
151 | ensure("command line parse failure", !ok); | 151 | ensure("command line parse failure", !ok); |
152 | } | 152 | } |
153 | |||
154 | |||
155 | template<> template<> | ||
156 | void application_object_t::test<5>() | ||
157 | { | ||
158 | LLSD options; | ||
159 | options["boolean-test"] = true; | ||
160 | mApp->setOptionData(LLApp::PRIORITY_GENERAL_CONFIGURATION, options); | ||
161 | ensure("bool set", mApp->getOption("boolean-test").asBoolean()); | ||
162 | options["boolean-test"] = false; | ||
163 | mApp->setOptionData(LLApp::PRIORITY_RUNTIME_OVERRIDE, options); | ||
164 | ensure("bool unset", !mApp->getOption("boolean-test").asBoolean()); | ||
165 | } | ||
153 | } | 166 | } |
diff --git a/linden/indra/test/llbase64_tut.cpp b/linden/indra/test/llbase64_tut.cpp new file mode 100644 index 0000000..fe02397 --- /dev/null +++ b/linden/indra/test/llbase64_tut.cpp | |||
@@ -0,0 +1,77 @@ | |||
1 | /** | ||
2 | * @file llbase64_tut.cpp | ||
3 | * @author James Cook | ||
4 | * @date 2007-02-04 | ||
5 | * | ||
6 | * Copyright (c) 2007-2007, Linden Research, Inc. | ||
7 | * | ||
8 | * The source code in this file ("Source Code") is provided by Linden Lab | ||
9 | * to you under the terms of the GNU General Public License, version 2.0 | ||
10 | * ("GPL"), unless you have obtained a separate licensing agreement | ||
11 | * ("Other License"), formally executed by you and Linden Lab. Terms of | ||
12 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
13 | * online at http://secondlife.com/developers/opensource/gplv2 | ||
14 | * | ||
15 | * There are special exceptions to the terms and conditions of the GPL as | ||
16 | * it is applied to this Source Code. View the full text of the exception | ||
17 | * in the file doc/FLOSS-exception.txt in this software distribution, or | ||
18 | * online at http://secondlife.com/developers/opensource/flossexception | ||
19 | * | ||
20 | * By copying, modifying or distributing this software, you acknowledge | ||
21 | * that you have read and understood your obligations described above, | ||
22 | * and agree to abide by those obligations. | ||
23 | * | ||
24 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
25 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
26 | * COMPLETENESS OR PERFORMANCE. | ||
27 | */ | ||
28 | |||
29 | #include "linden_common.h" | ||
30 | #include "lltut.h" | ||
31 | |||
32 | #include "llbase64.h" | ||
33 | |||
34 | #include <string> | ||
35 | #include "lluuid.h" | ||
36 | |||
37 | namespace tut | ||
38 | { | ||
39 | struct base64_data | ||
40 | { | ||
41 | }; | ||
42 | typedef test_group<base64_data> base64_test; | ||
43 | typedef base64_test::object base64_object; | ||
44 | tut::base64_test base64("base64"); | ||
45 | |||
46 | template<> template<> | ||
47 | void base64_object::test<1>() | ||
48 | { | ||
49 | std::string result; | ||
50 | |||
51 | result = LLBase64::encode(NULL, 0); | ||
52 | ensure("encode nothing", (result == "") ); | ||
53 | |||
54 | LLUUID nothing; | ||
55 | result = LLBase64::encode(¬hing.mData[0], UUID_BYTES); | ||
56 | ensure("encode blank uuid", | ||
57 | (result == "AAAAAAAAAAAAAAAAAAAAAA==") ); | ||
58 | |||
59 | LLUUID id("526a1e07-a19d-baed-84c4-ff08a488d15e"); | ||
60 | result = LLBase64::encode(&id.mData[0], UUID_BYTES); | ||
61 | ensure("encode random uuid", | ||
62 | (result == "UmoeB6Gduu2ExP8IpIjRXg==") ); | ||
63 | |||
64 | } | ||
65 | |||
66 | template<> template<> | ||
67 | void base64_object::test<2>() | ||
68 | { | ||
69 | std::string result; | ||
70 | |||
71 | U8 blob[40] = { 115, 223, 172, 255, 140, 70, 49, 125, 236, 155, 45, 199, 101, 17, 164, 131, 230, 19, 80, 64, 112, 53, 135, 98, 237, 12, 26, 72, 126, 14, 145, 143, 118, 196, 11, 177, 132, 169, 195, 134 }; | ||
72 | result = LLBase64::encode(&blob[0], 40); | ||
73 | ensure("encode 40 bytes", | ||
74 | (result == "c9+s/4xGMX3smy3HZRGkg+YTUEBwNYdi7QwaSH4OkY92xAuxhKnDhg==") ); | ||
75 | } | ||
76 | |||
77 | } | ||
diff --git a/linden/indra/test/llblowfish_tut.cpp b/linden/indra/test/llblowfish_tut.cpp new file mode 100644 index 0000000..0d85ade --- /dev/null +++ b/linden/indra/test/llblowfish_tut.cpp | |||
@@ -0,0 +1,144 @@ | |||
1 | /** | ||
2 | * @file llblowfish_tut.cpp | ||
3 | * @author James Cook, james@lindenlab.com | ||
4 | * @date 2007-02-04 | ||
5 | * | ||
6 | * Data files generated with: | ||
7 | * openssl enc -bf-cbc -in blowfish.digits.txt -out blowfish.1.bin -K 00000000000000000000000000000000 -iv 0000000000000000 -p | ||
8 | * openssl enc -bf-cbc -in blowfish.digits.txt -out blowfish.2.bin -K 526a1e07a19dbaed84c4ff08a488d15e -iv 0000000000000000 -p | ||
9 | * | ||
10 | * Copyright (c) 2007-2007, Linden Research, Inc. | ||
11 | * | ||
12 | * The source code in this file ("Source Code") is provided by Linden Lab | ||
13 | * to you under the terms of the GNU General Public License, version 2.0 | ||
14 | * ("GPL"), unless you have obtained a separate licensing agreement | ||
15 | * ("Other License"), formally executed by you and Linden Lab. Terms of | ||
16 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
17 | * online at http://secondlife.com/developers/opensource/gplv2 | ||
18 | * | ||
19 | * There are special exceptions to the terms and conditions of the GPL as | ||
20 | * it is applied to this Source Code. View the full text of the exception | ||
21 | * in the file doc/FLOSS-exception.txt in this software distribution, or | ||
22 | * online at http://secondlife.com/developers/opensource/flossexception | ||
23 | * | ||
24 | * By copying, modifying or distributing this software, you acknowledge | ||
25 | * that you have read and understood your obligations described above, | ||
26 | * and agree to abide by those obligations. | ||
27 | * | ||
28 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
29 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
30 | * COMPLETENESS OR PERFORMANCE. | ||
31 | */ | ||
32 | |||
33 | #include "linden_common.h" | ||
34 | #include "lltut.h" | ||
35 | |||
36 | #include "llblowfishcipher.h" | ||
37 | |||
38 | #include <string> | ||
39 | #include <stdio.h> | ||
40 | #include "lluuid.h" | ||
41 | |||
42 | namespace tut | ||
43 | { | ||
44 | class LLData | ||
45 | { | ||
46 | public: | ||
47 | unsigned char* mInput; | ||
48 | int mInputSize; | ||
49 | |||
50 | LLData() | ||
51 | { | ||
52 | // \n to make it easier to create text files | ||
53 | // for testing with command line openssl | ||
54 | mInput = (unsigned char*)"01234567890123456789012345678901234\n"; | ||
55 | mInputSize = 36; | ||
56 | } | ||
57 | |||
58 | bool matchFile(const char* filename, | ||
59 | const std::string& data) | ||
60 | { | ||
61 | FILE* fp = fopen(filename, "rb"); | ||
62 | if (!fp) | ||
63 | { | ||
64 | // sometimes test is run inside the indra directory | ||
65 | std::string path = "test/"; | ||
66 | path += filename; | ||
67 | fp = fopen(path.c_str(), "rb"); | ||
68 | } | ||
69 | if (!fp) | ||
70 | { | ||
71 | llwarns << "unabled to open " << filename << llendl; | ||
72 | return false; | ||
73 | } | ||
74 | |||
75 | std::string good; | ||
76 | good.resize(256); | ||
77 | size_t got = fread(&good[0], 1, 256, fp); | ||
78 | lldebugs << "matchFile read " << got << llendl; | ||
79 | fclose(fp); | ||
80 | good.resize(got); | ||
81 | |||
82 | return (good == data); | ||
83 | } | ||
84 | }; | ||
85 | typedef test_group<LLData> blowfish_test; | ||
86 | typedef blowfish_test::object blowfish_object; | ||
87 | // Create test with name that can be selected on | ||
88 | // command line of test app. | ||
89 | tut::blowfish_test blowfish("blowfish"); | ||
90 | |||
91 | template<> template<> | ||
92 | void blowfish_object::test<1>() | ||
93 | { | ||
94 | LLUUID blank; | ||
95 | LLBlowfishCipher cipher(&blank.mData[0], UUID_BYTES); | ||
96 | |||
97 | U32 dst_len = cipher.requiredEncryptionSpace(36); | ||
98 | ensure("encryption space 36", | ||
99 | (dst_len == 40) ); | ||
100 | |||
101 | // Blowfish adds an additional 8-byte block if your | ||
102 | // input is an exact multiple of 8 | ||
103 | dst_len = cipher.requiredEncryptionSpace(8); | ||
104 | ensure("encryption space 8", | ||
105 | (dst_len == 16) ); | ||
106 | } | ||
107 | |||
108 | template<> template<> | ||
109 | void blowfish_object::test<2>() | ||
110 | { | ||
111 | LLUUID blank; | ||
112 | LLBlowfishCipher cipher(&blank.mData[0], UUID_BYTES); | ||
113 | |||
114 | std::string result; | ||
115 | result.resize(256); | ||
116 | U32 count = cipher.encrypt(mInput, mInputSize, | ||
117 | (U8*) &result[0], 256); | ||
118 | |||
119 | ensure("encrypt output count", | ||
120 | (count == 40) ); | ||
121 | result.resize(count); | ||
122 | |||
123 | ensure("encrypt null key", matchFile("blowfish.1.bin", result)); | ||
124 | } | ||
125 | |||
126 | template<> template<> | ||
127 | void blowfish_object::test<3>() | ||
128 | { | ||
129 | // same as base64 test id | ||
130 | LLUUID id("526a1e07-a19d-baed-84c4-ff08a488d15e"); | ||
131 | LLBlowfishCipher cipher(&id.mData[0], UUID_BYTES); | ||
132 | |||
133 | std::string result; | ||
134 | result.resize(256); | ||
135 | U32 count = cipher.encrypt(mInput, mInputSize, | ||
136 | (U8*) &result[0], 256); | ||
137 | |||
138 | ensure("encrypt output count", | ||
139 | (count == 40) ); | ||
140 | result.resize(count); | ||
141 | |||
142 | ensure("encrypt real key", matchFile("blowfish.2.bin", result)); | ||
143 | } | ||
144 | } | ||
diff --git a/linden/indra/test/llerror_tut.cpp b/linden/indra/test/llerror_tut.cpp new file mode 100644 index 0000000..a4b4258 --- /dev/null +++ b/linden/indra/test/llerror_tut.cpp | |||
@@ -0,0 +1,767 @@ | |||
1 | /** | ||
2 | * @file llerror_tut.cpp | ||
3 | * @date December 2006 | ||
4 | * @brief error unit tests | ||
5 | * | ||
6 | * Copyright (c) 2006-2007, Linden Research, Inc. | ||
7 | * | ||
8 | * The source code in this file ("Source Code") is provided by Linden Lab | ||
9 | * to you under the terms of the GNU General Public License, version 2.0 | ||
10 | * ("GPL"), unless you have obtained a separate licensing agreement | ||
11 | * ("Other License"), formally executed by you and Linden Lab. Terms of | ||
12 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
13 | * online at http://secondlife.com/developers/opensource/gplv2 | ||
14 | * | ||
15 | * There are special exceptions to the terms and conditions of the GPL as | ||
16 | * it is applied to this Source Code. View the full text of the exception | ||
17 | * in the file doc/FLOSS-exception.txt in this software distribution, or | ||
18 | * online at http://secondlife.com/developers/opensource/flossexception | ||
19 | * | ||
20 | * By copying, modifying or distributing this software, you acknowledge | ||
21 | * that you have read and understood your obligations described above, | ||
22 | * and agree to abide by those obligations. | ||
23 | * | ||
24 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
25 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
26 | * COMPLETENESS OR PERFORMANCE. | ||
27 | */ | ||
28 | |||
29 | #include "llerror.h" | ||
30 | namespace | ||
31 | { | ||
32 | void test_that_error_h_includes_enough_things_to_compile_a_message() | ||
33 | { | ||
34 | llinfos << "!" << llendl; | ||
35 | } | ||
36 | } | ||
37 | |||
38 | #include <tut/tut.h> | ||
39 | #include "lltut.h" | ||
40 | |||
41 | #include <vector> | ||
42 | |||
43 | #include "llerrorcontrol.h" | ||
44 | #include "llsd.h" | ||
45 | |||
46 | namespace | ||
47 | { | ||
48 | static bool fatalWasCalled; | ||
49 | void fatalCall(const std::string&) { fatalWasCalled = true; } | ||
50 | |||
51 | class TestRecorder : public LLError::Recorder | ||
52 | { | ||
53 | public: | ||
54 | TestRecorder() : mWantsTime(false) { } | ||
55 | ~TestRecorder() { LLError::removeRecorder(this); } | ||
56 | |||
57 | void recordMessage(LLError::ELevel level, | ||
58 | const std::string& message) | ||
59 | { | ||
60 | mMessages.push_back(message); | ||
61 | } | ||
62 | |||
63 | int countMessages() { return (int) mMessages.size(); } | ||
64 | void clearMessages() { mMessages.clear(); } | ||
65 | |||
66 | void setWantsTime(bool t) { mWantsTime = t; } | ||
67 | bool wantsTime() { return mWantsTime; } | ||
68 | |||
69 | std::string message(int n) | ||
70 | { | ||
71 | std::ostringstream test_name; | ||
72 | test_name << "testing message " << n << ", not enough messages"; | ||
73 | |||
74 | tut::ensure(test_name.str(), n < countMessages()); | ||
75 | return mMessages[n]; | ||
76 | } | ||
77 | |||
78 | private: | ||
79 | typedef std::vector<std::string> MessageVector; | ||
80 | MessageVector mMessages; | ||
81 | |||
82 | bool mWantsTime; | ||
83 | }; | ||
84 | } | ||
85 | |||
86 | namespace tut | ||
87 | { | ||
88 | struct ErrorTestData | ||
89 | { | ||
90 | TestRecorder mRecorder; | ||
91 | LLError::Settings* mPriorErrorSettings; | ||
92 | |||
93 | ErrorTestData() | ||
94 | { | ||
95 | fatalWasCalled = false; | ||
96 | |||
97 | mPriorErrorSettings = LLError::saveAndResetSettings(); | ||
98 | LLError::setDefaultLevel(LLError::LEVEL_DEBUG); | ||
99 | LLError::setFatalFunction(fatalCall); | ||
100 | LLError::addRecorder(&mRecorder); | ||
101 | } | ||
102 | |||
103 | ~ErrorTestData() | ||
104 | { | ||
105 | LLError::removeRecorder(&mRecorder); | ||
106 | LLError::restoreSettings(mPriorErrorSettings); | ||
107 | } | ||
108 | |||
109 | void ensure_message_count(int expectedCount) | ||
110 | { | ||
111 | ensure_equals("message count", mRecorder.countMessages(), expectedCount); | ||
112 | } | ||
113 | |||
114 | void ensure_message_contains(int n, const std::string& expectedText) | ||
115 | { | ||
116 | std::ostringstream test_name; | ||
117 | test_name << "testing message " << n; | ||
118 | |||
119 | ensure_contains(test_name.str(), mRecorder.message(n), expectedText); | ||
120 | } | ||
121 | |||
122 | void ensure_message_does_not_contain(int n, const std::string& expectedText) | ||
123 | { | ||
124 | std::ostringstream test_name; | ||
125 | test_name << "testing message " << n; | ||
126 | |||
127 | ensure_does_not_contain(test_name.str(), mRecorder.message(n), expectedText); | ||
128 | } | ||
129 | }; | ||
130 | |||
131 | typedef test_group<ErrorTestData> ErrorTestGroup; | ||
132 | typedef ErrorTestGroup::object ErrorTestObject; | ||
133 | |||
134 | ErrorTestGroup errorTestGroup("error"); | ||
135 | |||
136 | template<> template<> | ||
137 | void ErrorTestObject::test<1>() | ||
138 | // basic test of output | ||
139 | { | ||
140 | llinfos << "test" << llendl; | ||
141 | llinfos << "bob" << llendl; | ||
142 | |||
143 | ensure_message_contains(0, "test"); | ||
144 | ensure_message_contains(1, "bob"); | ||
145 | } | ||
146 | } | ||
147 | |||
148 | namespace | ||
149 | { | ||
150 | void writeSome() | ||
151 | { | ||
152 | lldebugs << "one" << llendl; | ||
153 | llinfos << "two" << llendl; | ||
154 | llwarns << "three" << llendl; | ||
155 | llerrs << "four" << llendl; | ||
156 | // fatal messages write out and addtional "error" message | ||
157 | } | ||
158 | }; | ||
159 | |||
160 | namespace tut | ||
161 | { | ||
162 | template<> template<> | ||
163 | void ErrorTestObject::test<2>() | ||
164 | // messages are filtered based on default level | ||
165 | { | ||
166 | LLError::setDefaultLevel(LLError::LEVEL_DEBUG); | ||
167 | writeSome(); | ||
168 | ensure_message_contains(0, "one"); | ||
169 | ensure_message_contains(1, "two"); | ||
170 | ensure_message_contains(2, "three"); | ||
171 | ensure_message_contains(3, "error"); | ||
172 | ensure_message_contains(4, "four"); | ||
173 | ensure_message_count(5); | ||
174 | |||
175 | LLError::setDefaultLevel(LLError::LEVEL_INFO); | ||
176 | writeSome(); | ||
177 | ensure_message_contains(5, "two"); | ||
178 | ensure_message_contains(6, "three"); | ||
179 | ensure_message_contains(7, "error"); | ||
180 | ensure_message_contains(8, "four"); | ||
181 | ensure_message_count(9); | ||
182 | |||
183 | LLError::setDefaultLevel(LLError::LEVEL_WARN); | ||
184 | writeSome(); | ||
185 | ensure_message_contains(9, "three"); | ||
186 | ensure_message_contains(10, "error"); | ||
187 | ensure_message_contains(11, "four"); | ||
188 | ensure_message_count(12); | ||
189 | |||
190 | LLError::setDefaultLevel(LLError::LEVEL_ERROR); | ||
191 | writeSome(); | ||
192 | ensure_message_contains(12, "error"); | ||
193 | ensure_message_contains(13, "four"); | ||
194 | ensure_message_count(14); | ||
195 | |||
196 | LLError::setDefaultLevel(LLError::LEVEL_NONE); | ||
197 | writeSome(); | ||
198 | ensure_message_count(14); | ||
199 | } | ||
200 | |||
201 | template<> template<> | ||
202 | void ErrorTestObject::test<3>() | ||
203 | // error type string in output | ||
204 | { | ||
205 | writeSome(); | ||
206 | ensure_message_contains(0, "DEBUG: "); | ||
207 | ensure_message_contains(1, "INFO: "); | ||
208 | ensure_message_contains(2, "WARNING: "); | ||
209 | ensure_message_does_not_contain(3, "ERROR"); | ||
210 | ensure_message_contains(4, "ERROR: "); | ||
211 | ensure_message_count(5); | ||
212 | } | ||
213 | |||
214 | template<> template<> | ||
215 | void ErrorTestObject::test<4>() | ||
216 | // file abbreviation | ||
217 | { | ||
218 | std::string thisFile = __FILE__; | ||
219 | std::string abbreviateFile = LLError::abbreviateFile(thisFile); | ||
220 | |||
221 | ensure_ends_with("file name abbreviation", | ||
222 | abbreviateFile, | ||
223 | "test/llerror_tut.cpp" | ||
224 | ); | ||
225 | ensure_does_not_contain("file name abbreviation", | ||
226 | abbreviateFile, "indra"); | ||
227 | |||
228 | std::string someFile = | ||
229 | #if LL_WINDOWS | ||
230 | "C:/amy/bob/cam.cpp" | ||
231 | #else | ||
232 | "/amy/bob/cam.cpp" | ||
233 | #endif | ||
234 | ; | ||
235 | std::string someAbbreviation = LLError::abbreviateFile(someFile); | ||
236 | |||
237 | ensure_equals("non-indra file abbreviation", | ||
238 | someAbbreviation, someFile); | ||
239 | } | ||
240 | } | ||
241 | |||
242 | namespace | ||
243 | { | ||
244 | std::string locationString(int line) | ||
245 | { | ||
246 | std::ostringstream location; | ||
247 | location << LLError::abbreviateFile(__FILE__) | ||
248 | << "(" << line << ") : "; | ||
249 | |||
250 | return location.str(); | ||
251 | } | ||
252 | |||
253 | std::string writeReturningLocation() | ||
254 | { | ||
255 | llinfos << "apple" << llendl; int this_line = __LINE__; | ||
256 | return locationString(this_line); | ||
257 | } | ||
258 | |||
259 | std::string writeReturningLocationAndFunction() | ||
260 | { | ||
261 | llinfos << "apple" << llendl; int this_line = __LINE__; | ||
262 | return locationString(this_line) + __FUNCTION__; | ||
263 | } | ||
264 | |||
265 | std::string errorReturningLocation() | ||
266 | { | ||
267 | llerrs << "die" << llendl; int this_line = __LINE__; | ||
268 | return locationString(this_line); | ||
269 | } | ||
270 | } | ||
271 | |||
272 | namespace tut | ||
273 | { | ||
274 | template<> template<> | ||
275 | void ErrorTestObject::test<5>() | ||
276 | // file and line information in log messages | ||
277 | { | ||
278 | std::string location = writeReturningLocation(); | ||
279 | // expecting default to not print location information | ||
280 | |||
281 | LLError::setPrintLocation(true); | ||
282 | writeReturningLocation(); | ||
283 | |||
284 | LLError::setPrintLocation(false); | ||
285 | writeReturningLocation(); | ||
286 | |||
287 | ensure_message_does_not_contain(0, location); | ||
288 | ensure_message_contains(1, location); | ||
289 | ensure_message_does_not_contain(2, location); | ||
290 | } | ||
291 | } | ||
292 | |||
293 | /* The following helper functions and class members all log a simple message | ||
294 | from some particular function scope. Each function takes a bool argument | ||
295 | that indicates if it should log its own name or not (in the manner that | ||
296 | existing log messages often do.) The functions all return their C++ | ||
297 | name so that test can be substantial mechanized. | ||
298 | */ | ||
299 | |||
300 | std::string logFromGlobal(bool id) | ||
301 | { | ||
302 | llinfos << (id ? "logFromGlobal: " : "") << "hi" << llendl; | ||
303 | return "logFromGlobal"; | ||
304 | } | ||
305 | |||
306 | static std::string logFromStatic(bool id) | ||
307 | { | ||
308 | llinfos << (id ? "logFromStatic: " : "") << "hi" << llendl; | ||
309 | return "logFromStatic"; | ||
310 | } | ||
311 | |||
312 | namespace | ||
313 | { | ||
314 | std::string logFromAnon(bool id) | ||
315 | { | ||
316 | llinfos << (id ? "logFromAnon: " : "") << "hi" << llendl; | ||
317 | return "logFromAnon"; | ||
318 | } | ||
319 | } | ||
320 | |||
321 | namespace Foo { | ||
322 | std::string logFromNamespace(bool id) | ||
323 | { | ||
324 | llinfos << (id ? "Foo::logFromNamespace: " : "") << "hi" << llendl; | ||
325 | //return "Foo::logFromNamespace"; | ||
326 | // there is no standard way to get the namespace name, hence | ||
327 | // we won't be testing for it | ||
328 | return "logFromNamespace"; | ||
329 | } | ||
330 | } | ||
331 | |||
332 | namespace | ||
333 | { | ||
334 | class ClassWithNoLogType { | ||
335 | public: | ||
336 | std::string logFromMember(bool id) | ||
337 | { | ||
338 | llinfos << (id ? "ClassWithNoLogType::logFromMember: " : "") << "hi" << llendl; | ||
339 | return "ClassWithNoLogType::logFromMember"; | ||
340 | } | ||
341 | static std::string logFromStatic(bool id) | ||
342 | { | ||
343 | llinfos << (id ? "ClassWithNoLogType::logFromStatic: " : "") << "hi" << llendl; | ||
344 | return "ClassWithNoLogType::logFromStatic"; | ||
345 | } | ||
346 | }; | ||
347 | |||
348 | class ClassWithLogType { | ||
349 | LOG_CLASS(ClassWithLogType); | ||
350 | public: | ||
351 | std::string logFromMember(bool id) | ||
352 | { | ||
353 | llinfos << (id ? "ClassWithLogType::logFromMember: " : "") << "hi" << llendl; | ||
354 | return "ClassWithLogType::logFromMember"; | ||
355 | } | ||
356 | static std::string logFromStatic(bool id) | ||
357 | { | ||
358 | llinfos << (id ? "ClassWithLogType::logFromStatic: " : "") << "hi" << llendl; | ||
359 | return "ClassWithLogType::logFromStatic"; | ||
360 | } | ||
361 | }; | ||
362 | |||
363 | std::string logFromNamespace(bool id) { return Foo::logFromNamespace(id); } | ||
364 | std::string logFromClassWithNoLogTypeMember(bool id) { ClassWithNoLogType c; return c.logFromMember(id); } | ||
365 | std::string logFromClassWithNoLogTypeStatic(bool id) { return ClassWithNoLogType::logFromStatic(id); } | ||
366 | std::string logFromClassWithLogTypeMember(bool id) { ClassWithLogType c; return c.logFromMember(id); } | ||
367 | std::string logFromClassWithLogTypeStatic(bool id) { return ClassWithLogType::logFromStatic(id); } | ||
368 | |||
369 | void ensure_has_once(const std::string& message, | ||
370 | const std::string& actual, const std::string& expected) | ||
371 | { | ||
372 | std::string::size_type n1 = actual.find(expected); | ||
373 | std::string::size_type n2 = std::string::npos; | ||
374 | if (n1 != std::string::npos) | ||
375 | { | ||
376 | n2 = std::string(actual, n1 + expected.size()).find(expected); | ||
377 | } | ||
378 | |||
379 | if (n1 == std::string::npos || n2 != std::string::npos) | ||
380 | { | ||
381 | std::stringstream ss; | ||
382 | ss << message << ": " << "expected to find one copy of " << expected | ||
383 | << " in actual " << actual; | ||
384 | throw tut::failure(ss.str().c_str()); | ||
385 | } | ||
386 | } | ||
387 | |||
388 | typedef std::string (*LogFromFunction)(bool); | ||
389 | void testLogNameOnce(TestRecorder& recorder, LogFromFunction f, | ||
390 | const std::string& class_name = "") | ||
391 | { | ||
392 | recorder.clearMessages(); | ||
393 | std::string name = f(false); | ||
394 | f(true); | ||
395 | |||
396 | std::string messageWithoutName = recorder.message(0); | ||
397 | std::string messageWithName = recorder.message(1); | ||
398 | |||
399 | ensure_has_once(name + " logged without name", | ||
400 | messageWithoutName, name); | ||
401 | ensure_has_once(name + " logged with name", | ||
402 | messageWithName, name); | ||
403 | |||
404 | if (!class_name.empty()) | ||
405 | { | ||
406 | ensure_has_once(name + "logged without name", | ||
407 | messageWithoutName, class_name); | ||
408 | ensure_has_once(name + "logged with name", | ||
409 | messageWithName, class_name); | ||
410 | } | ||
411 | } | ||
412 | } | ||
413 | |||
414 | namespace tut | ||
415 | { | ||
416 | template<> template<> | ||
417 | // class/function information in output | ||
418 | void ErrorTestObject::test<6>() | ||
419 | { | ||
420 | testLogNameOnce(mRecorder, logFromGlobal); | ||
421 | testLogNameOnce(mRecorder, logFromStatic); | ||
422 | testLogNameOnce(mRecorder, logFromAnon); | ||
423 | testLogNameOnce(mRecorder, logFromNamespace); | ||
424 | //testLogNameOnce(mRecorder, logFromClassWithNoLogTypeMember, "ClassWithNoLogType"); | ||
425 | //testLogNameOnce(mRecorder, logFromClassWithNoLogTypeStatic, "ClassWithNoLogType"); | ||
426 | // XXX: figure out what the exepcted response is for these | ||
427 | testLogNameOnce(mRecorder, logFromClassWithLogTypeMember, "ClassWithLogType"); | ||
428 | testLogNameOnce(mRecorder, logFromClassWithLogTypeStatic, "ClassWithLogType"); | ||
429 | } | ||
430 | } | ||
431 | |||
432 | namespace | ||
433 | { | ||
434 | std::string innerLogger() | ||
435 | { | ||
436 | llinfos << "inside" << llendl; | ||
437 | return "moo"; | ||
438 | } | ||
439 | |||
440 | std::string outerLogger() | ||
441 | { | ||
442 | llinfos << "outside(" << innerLogger() << ")" << llendl; | ||
443 | return "bar"; | ||
444 | } | ||
445 | |||
446 | void uberLogger() | ||
447 | { | ||
448 | llinfos << "uber(" << outerLogger() << "," << innerLogger() << ")" << llendl; | ||
449 | } | ||
450 | |||
451 | class LogWhileLogging | ||
452 | { | ||
453 | public: | ||
454 | void print(std::ostream& out) const | ||
455 | { | ||
456 | llinfos << "logging" << llendl; | ||
457 | out << "baz"; | ||
458 | } | ||
459 | }; | ||
460 | |||
461 | std::ostream& operator<<(std::ostream& out, const LogWhileLogging& l) | ||
462 | { l.print(out); return out; } | ||
463 | |||
464 | void metaLogger() | ||
465 | { | ||
466 | LogWhileLogging l; | ||
467 | llinfos << "meta(" << l << ")" << llendl; | ||
468 | } | ||
469 | |||
470 | } | ||
471 | |||
472 | namespace tut | ||
473 | { | ||
474 | template<> template<> | ||
475 | // handle nested logging | ||
476 | void ErrorTestObject::test<7>() | ||
477 | { | ||
478 | outerLogger(); | ||
479 | ensure_message_contains(0, "inside"); | ||
480 | ensure_message_contains(1, "outside(moo)"); | ||
481 | ensure_message_count(2); | ||
482 | |||
483 | uberLogger(); | ||
484 | ensure_message_contains(2, "inside"); | ||
485 | ensure_message_contains(3, "inside"); | ||
486 | ensure_message_contains(4, "outside(moo)"); | ||
487 | ensure_message_contains(5, "uber(bar,moo)"); | ||
488 | ensure_message_count(6); | ||
489 | |||
490 | metaLogger(); | ||
491 | ensure_message_contains(6, "logging"); | ||
492 | ensure_message_contains(7, "meta(baz)"); | ||
493 | ensure_message_count(8); | ||
494 | } | ||
495 | |||
496 | template<> template<> | ||
497 | // special handling of llerrs calls | ||
498 | void ErrorTestObject::test<8>() | ||
499 | { | ||
500 | LLError::setPrintLocation(false); | ||
501 | std::string location = errorReturningLocation(); | ||
502 | |||
503 | ensure_message_contains(0, location + "error"); | ||
504 | ensure_message_contains(1, "die"); | ||
505 | ensure_message_count(2); | ||
506 | |||
507 | ensure("fatal callback called", fatalWasCalled); | ||
508 | } | ||
509 | } | ||
510 | |||
511 | namespace | ||
512 | { | ||
513 | std::string roswell() | ||
514 | { | ||
515 | return "1947-07-08T03:04:05Z"; | ||
516 | } | ||
517 | |||
518 | void ufoSighting() | ||
519 | { | ||
520 | llinfos << "ufo" << llendl; | ||
521 | } | ||
522 | } | ||
523 | |||
524 | namespace tut | ||
525 | { | ||
526 | template<> template<> | ||
527 | // time in output (for recorders that need it) | ||
528 | void ErrorTestObject::test<9>() | ||
529 | { | ||
530 | LLError::setTimeFunction(roswell); | ||
531 | |||
532 | mRecorder.setWantsTime(false); | ||
533 | ufoSighting(); | ||
534 | ensure_message_contains(0, "ufo"); | ||
535 | ensure_message_does_not_contain(0, roswell()); | ||
536 | |||
537 | mRecorder.setWantsTime(true); | ||
538 | ufoSighting(); | ||
539 | ensure_message_contains(1, "ufo"); | ||
540 | ensure_message_contains(1, roswell()); | ||
541 | } | ||
542 | |||
543 | template<> template<> | ||
544 | // output order | ||
545 | void ErrorTestObject::test<10>() | ||
546 | { | ||
547 | LLError::setPrintLocation(true); | ||
548 | LLError::setTimeFunction(roswell); | ||
549 | mRecorder.setWantsTime(true); | ||
550 | std::string locationAndFunction = writeReturningLocationAndFunction(); | ||
551 | |||
552 | ensure_equals("order is time type location function message", | ||
553 | mRecorder.message(0), | ||
554 | roswell() + " INFO: " + locationAndFunction + ": apple"); | ||
555 | } | ||
556 | |||
557 | template<> template<> | ||
558 | // multiple recorders | ||
559 | void ErrorTestObject::test<11>() | ||
560 | { | ||
561 | TestRecorder altRecorder; | ||
562 | LLError::addRecorder(&altRecorder); | ||
563 | |||
564 | llinfos << "boo" << llendl; | ||
565 | |||
566 | ensure_message_contains(0, "boo"); | ||
567 | ensure_equals("alt recorder count", altRecorder.countMessages(), 1); | ||
568 | ensure_contains("alt recorder message 0", altRecorder.message(0), "boo"); | ||
569 | |||
570 | LLError::setTimeFunction(roswell); | ||
571 | |||
572 | TestRecorder anotherRecorder; | ||
573 | anotherRecorder.setWantsTime(true); | ||
574 | LLError::addRecorder(&anotherRecorder); | ||
575 | |||
576 | llinfos << "baz" << llendl; | ||
577 | |||
578 | std::string when = roswell(); | ||
579 | |||
580 | ensure_message_does_not_contain(1, when); | ||
581 | ensure_equals("alt recorder count", altRecorder.countMessages(), 2); | ||
582 | ensure_does_not_contain("alt recorder message 1", altRecorder.message(1), when); | ||
583 | ensure_equals("another recorder count", anotherRecorder.countMessages(), 1); | ||
584 | ensure_contains("another recorder message 0", anotherRecorder.message(0), when); | ||
585 | } | ||
586 | } | ||
587 | |||
588 | class TestAlpha | ||
589 | { | ||
590 | LOG_CLASS(TestAlpha); | ||
591 | public: | ||
592 | static void doDebug() { lldebugs << "add dice" << llendl; } | ||
593 | static void doInfo() { llinfos << "any idea" << llendl; } | ||
594 | static void doWarn() { llwarns << "aim west" << llendl; } | ||
595 | static void doError() { llerrs << "ate eels" << llendl; } | ||
596 | static void doAll() { doDebug(); doInfo(); doWarn(); doError(); } | ||
597 | }; | ||
598 | |||
599 | class TestBeta | ||
600 | { | ||
601 | LOG_CLASS(TestBeta); | ||
602 | public: | ||
603 | static void doDebug() { lldebugs << "bed down" << llendl; } | ||
604 | static void doInfo() { llinfos << "buy iron" << llendl; } | ||
605 | static void doWarn() { llwarns << "bad word" << llendl; } | ||
606 | static void doError() { llerrs << "big easy" << llendl; } | ||
607 | static void doAll() { doDebug(); doInfo(); doWarn(); doError(); } | ||
608 | }; | ||
609 | |||
610 | namespace tut | ||
611 | { | ||
612 | template<> template<> | ||
613 | // filtering by class | ||
614 | void ErrorTestObject::test<12>() | ||
615 | { | ||
616 | LLError::setDefaultLevel(LLError::LEVEL_WARN); | ||
617 | LLError::setClassLevel("TestBeta", LLError::LEVEL_INFO); | ||
618 | |||
619 | TestAlpha::doAll(); | ||
620 | TestBeta::doAll(); | ||
621 | |||
622 | ensure_message_contains(0, "aim west"); | ||
623 | ensure_message_contains(1, "error"); | ||
624 | ensure_message_contains(2, "ate eels"); | ||
625 | ensure_message_contains(3, "buy iron"); | ||
626 | ensure_message_contains(4, "bad word"); | ||
627 | ensure_message_contains(5, "error"); | ||
628 | ensure_message_contains(6, "big easy"); | ||
629 | ensure_message_count(7); | ||
630 | } | ||
631 | |||
632 | template<> template<> | ||
633 | // filtering by function, and that it will override class filtering | ||
634 | void ErrorTestObject::test<13>() | ||
635 | { | ||
636 | LLError::setDefaultLevel(LLError::LEVEL_DEBUG); | ||
637 | LLError::setClassLevel("TestBeta", LLError::LEVEL_WARN); | ||
638 | LLError::setFunctionLevel("TestBeta::doInfo", LLError::LEVEL_DEBUG); | ||
639 | LLError::setFunctionLevel("TestBeta::doError", LLError::LEVEL_NONE); | ||
640 | |||
641 | TestBeta::doAll(); | ||
642 | ensure_message_contains(0, "buy iron"); | ||
643 | ensure_message_contains(1, "bad word"); | ||
644 | ensure_message_count(2); | ||
645 | } | ||
646 | |||
647 | template<> template<> | ||
648 | // filtering by file | ||
649 | // and that it is overridden by both class and function filtering | ||
650 | void ErrorTestObject::test<14>() | ||
651 | { | ||
652 | LLError::setDefaultLevel(LLError::LEVEL_DEBUG); | ||
653 | LLError::setFileLevel(LLError::abbreviateFile(__FILE__), | ||
654 | LLError::LEVEL_WARN); | ||
655 | LLError::setClassLevel("TestAlpha", LLError::LEVEL_INFO); | ||
656 | LLError::setFunctionLevel("TestAlpha::doError", | ||
657 | LLError::LEVEL_NONE); | ||
658 | LLError::setFunctionLevel("TestBeta::doError", | ||
659 | LLError::LEVEL_NONE); | ||
660 | |||
661 | TestAlpha::doAll(); | ||
662 | TestBeta::doAll(); | ||
663 | ensure_message_contains(0, "any idea"); | ||
664 | ensure_message_contains(1, "aim west"); | ||
665 | ensure_message_contains(2, "bad word"); | ||
666 | ensure_message_count(3); | ||
667 | } | ||
668 | |||
669 | template<> template<> | ||
670 | // proper cached, efficient lookup of filtering | ||
671 | void ErrorTestObject::test<15>() | ||
672 | { | ||
673 | LLError::setDefaultLevel(LLError::LEVEL_NONE); | ||
674 | |||
675 | TestAlpha::doInfo(); | ||
676 | ensure_message_count(0); | ||
677 | ensure_equals("first check", LLError::shouldLogCallCount(), 1); | ||
678 | TestAlpha::doInfo(); | ||
679 | ensure_message_count(0); | ||
680 | ensure_equals("second check", LLError::shouldLogCallCount(), 1); | ||
681 | |||
682 | LLError::setClassLevel("TestAlpha", LLError::LEVEL_DEBUG); | ||
683 | TestAlpha::doInfo(); | ||
684 | ensure_message_count(1); | ||
685 | ensure_equals("third check", LLError::shouldLogCallCount(), 2); | ||
686 | TestAlpha::doInfo(); | ||
687 | ensure_message_count(2); | ||
688 | ensure_equals("fourth check", LLError::shouldLogCallCount(), 2); | ||
689 | |||
690 | LLError::setClassLevel("TestAlpha", LLError::LEVEL_WARN); | ||
691 | TestAlpha::doInfo(); | ||
692 | ensure_message_count(2); | ||
693 | ensure_equals("fifth check", LLError::shouldLogCallCount(), 3); | ||
694 | TestAlpha::doInfo(); | ||
695 | ensure_message_count(2); | ||
696 | ensure_equals("sixth check", LLError::shouldLogCallCount(), 3); | ||
697 | } | ||
698 | |||
699 | template<> template<> | ||
700 | // configuration from LLSD | ||
701 | void ErrorTestObject::test<16>() | ||
702 | { | ||
703 | std::string this_file = LLError::abbreviateFile(__FILE__); | ||
704 | LLSD config; | ||
705 | config["print-location"] = true; | ||
706 | config["default-level"] = "DEBUG"; | ||
707 | |||
708 | LLSD set1; | ||
709 | set1["level"] = "WARN"; | ||
710 | set1["files"][0] = this_file; | ||
711 | |||
712 | LLSD set2; | ||
713 | set2["level"] = "INFO"; | ||
714 | set2["classes"][0] = "TestAlpha"; | ||
715 | |||
716 | LLSD set3; | ||
717 | set3["level"] = "NONE"; | ||
718 | set3["functions"][0] = "TestAlpha::doError"; | ||
719 | set3["functions"][1] = "TestBeta::doError"; | ||
720 | |||
721 | config["settings"][0] = set1; | ||
722 | config["settings"][1] = set2; | ||
723 | config["settings"][2] = set3; | ||
724 | |||
725 | LLError::configure(config); | ||
726 | |||
727 | TestAlpha::doAll(); | ||
728 | TestBeta::doAll(); | ||
729 | ensure_message_contains(0, "any idea"); | ||
730 | ensure_message_contains(0, this_file); | ||
731 | ensure_message_contains(1, "aim west"); | ||
732 | ensure_message_contains(2, "bad word"); | ||
733 | ensure_message_count(3); | ||
734 | |||
735 | // make sure reconfiguring works | ||
736 | LLSD config2; | ||
737 | config2["default-level"] = "WARN"; | ||
738 | |||
739 | LLError::configure(config2); | ||
740 | |||
741 | TestAlpha::doAll(); | ||
742 | TestBeta::doAll(); | ||
743 | ensure_message_contains(3, "aim west"); | ||
744 | ensure_message_does_not_contain(3, this_file); | ||
745 | ensure_message_contains(4, "error"); | ||
746 | ensure_message_contains(5, "ate eels"); | ||
747 | ensure_message_contains(6, "bad word"); | ||
748 | ensure_message_contains(7, "error"); | ||
749 | ensure_message_contains(8, "big easy"); | ||
750 | ensure_message_count(9); | ||
751 | } | ||
752 | } | ||
753 | |||
754 | /* Tests left: | ||
755 | handling of classes without LOG_CLASS | ||
756 | |||
757 | live update of filtering from file | ||
758 | |||
759 | syslog recorder | ||
760 | file recorder | ||
761 | cerr/stderr recorder | ||
762 | fixed buffer recorder | ||
763 | windows recorder | ||
764 | |||
765 | mutex use when logging (?) | ||
766 | strange careful about to crash handling (?) | ||
767 | */ | ||
diff --git a/linden/indra/test/llhttpclient_tut.cpp b/linden/indra/test/llhttpclient_tut.cpp index c84d34b..ef53e71 100644 --- a/linden/indra/test/llhttpclient_tut.cpp +++ b/linden/indra/test/llhttpclient_tut.cpp | |||
@@ -32,9 +32,10 @@ | |||
32 | */ | 32 | */ |
33 | 33 | ||
34 | #include <tut/tut.h> | 34 | #include <tut/tut.h> |
35 | #include "linden_common.h" | ||
35 | #include "lltut.h" | 36 | #include "lltut.h" |
36 | |||
37 | #include "llhttpclient.h" | 37 | #include "llhttpclient.h" |
38 | #include "llformat.h" | ||
38 | #include "llpipeutil.h" | 39 | #include "llpipeutil.h" |
39 | #include "llpumpio.h" | 40 | #include "llpumpio.h" |
40 | 41 | ||
@@ -312,4 +313,23 @@ namespace tut | |||
312 | ensureStatusError(); | 313 | ensureStatusError(); |
313 | ensure_equals("reason", mReason, "STATUS_ERROR"); | 314 | ensure_equals("reason", mReason, "STATUS_ERROR"); |
314 | } | 315 | } |
316 | |||
317 | template<> template<> | ||
318 | void HTTPClientTestObject::test<7>() | ||
319 | { | ||
320 | // Can not use the little mini server. The blocking request won't ever let it run. | ||
321 | // Instead get from a known LLSD source and compare results with the non-blocking get | ||
322 | // which is tested against the mini server earlier. | ||
323 | LLSD expected; | ||
324 | |||
325 | LLHTTPClient::get("http://secondlife.com/xmlhttp/homepage.php", newResult()); | ||
326 | runThePump(); | ||
327 | ensureStatusOK(); | ||
328 | expected = getResult(); | ||
329 | |||
330 | LLSD result; | ||
331 | result = LLHTTPClient::blockingGet("http://secondlife.com/xmlhttp/homepage.php"); | ||
332 | LLSD body = result["body"]; | ||
333 | ensure_equals("echoed result matches", body.size(), expected.size()); | ||
334 | } | ||
315 | } | 335 | } |
diff --git a/linden/indra/test/llpipeutil.cpp b/linden/indra/test/llpipeutil.cpp index 53c5991..2857f12 100644 --- a/linden/indra/test/llpipeutil.cpp +++ b/linden/indra/test/llpipeutil.cpp | |||
@@ -26,11 +26,15 @@ | |||
26 | * COMPLETENESS OR PERFORMANCE. | 26 | * COMPLETENESS OR PERFORMANCE. |
27 | */ | 27 | */ |
28 | 28 | ||
29 | |||
30 | #include "linden_common.h" | ||
29 | #include "llpipeutil.h" | 31 | #include "llpipeutil.h" |
30 | 32 | ||
31 | #include <stdlib.h> | 33 | #include <stdlib.h> |
34 | #include <sstream> | ||
32 | 35 | ||
33 | #include "llbufferstream.h" | 36 | #include "llbufferstream.h" |
37 | #include "lldefs.h" | ||
34 | #include "llframetimer.h" | 38 | #include "llframetimer.h" |
35 | #include "llpumpio.h" | 39 | #include "llpumpio.h" |
36 | #include "llrand.h" | 40 | #include "llrand.h" |
@@ -77,8 +81,8 @@ LLIOPipe::EStatus LLPipeStringExtractor::process_impl( | |||
77 | std::ostringstream ostr; | 81 | std::ostringstream ostr; |
78 | while (istr.good()) | 82 | while (istr.good()) |
79 | { | 83 | { |
80 | char buf[1024]; | 84 | char buf[1024]; /* Flawfinder: ignore */ |
81 | istr.read(buf, sizeof(buf)); | 85 | istr.read(buf, sizeof(buf)); /* Flawfinder: ignore */ |
82 | ostr.write(buf, istr.gcount()); | 86 | ostr.write(buf, istr.gcount()); |
83 | } | 87 | } |
84 | mString = ostr.str(); | 88 | mString = ostr.str(); |
diff --git a/linden/indra/test/llrandom_tut.cpp b/linden/indra/test/llrandom_tut.cpp index 1bb795e..a842dfd 100755 --- a/linden/indra/test/llrandom_tut.cpp +++ b/linden/indra/test/llrandom_tut.cpp | |||
@@ -1,9 +1,9 @@ | |||
1 | /** | 1 | /** |
2 | * @file llrandom_tut.cpp | 2 | * @file llrandom_tut.cpp |
3 | * @author Phoenix | 3 | * @author Phoenix |
4 | * @date 2007-01-25 | 4 | * @date 2007-01-25 |
5 | * | 5 | * |
6 | * Copyright (c) 2007-2007, Linden Research, Inc. | 6 | * Copyright (c) 2007-2007, Linden Research, Inc. |
7 | * | 7 | * |
8 | * The source code in this file ("Source Code") is provided by Linden Lab | 8 | * The source code in this file ("Source Code") is provided by Linden Lab |
9 | * to you under the terms of the GNU General Public License, version 2.0 | 9 | * to you under the terms of the GNU General Public License, version 2.0 |
@@ -23,47 +23,107 @@ | |||
23 | * | 23 | * |
24 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | 24 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO |
25 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | 25 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, |
26 | * COMPLETENESS OR PERFORMANCE. | 26 | * COMPLETENESS OR PERFORMANCE. |
27 | */ | 27 | */ |
28 | 28 | ||
29 | #include <tut/tut.h> | 29 | #include <tut/tut.h> |
30 | 30 | ||
31 | #include "linden_common.h" | 31 | #include "linden_common.h" |
32 | #include "llrand.h" | 32 | #include "llrand.h" |
33 | #include "lltut.h" | 33 | #include "lltut.h" |
34 | 34 | ||
35 | 35 | ||
36 | namespace tut | 36 | namespace tut |
37 | { | 37 | { |
38 | struct random | 38 | struct random |
39 | { | 39 | { |
40 | }; | 40 | }; |
41 | 41 | ||
42 | typedef test_group<random> random_t; | 42 | typedef test_group<random> random_t; |
43 | typedef random_t::object random_object_t; | 43 | typedef random_t::object random_object_t; |
44 | tut::random_t tut_random("random"); | 44 | tut::random_t tut_random("random"); |
45 | 45 | ||
46 | template<> template<> | 46 | template<> template<> |
47 | void random_object_t::test<1>() | 47 | void random_object_t::test<1>() |
48 | { | 48 | { |
49 | F32 number = 0.0f; | 49 | F32 number = 0.0f; |
50 | for(S32 ii = 0; ii < 100000; ++ii) | 50 | for(S32 ii = 0; ii < 100000; ++ii) |
51 | { | 51 | { |
52 | number = ll_frand(); | 52 | number = ll_frand(); |
53 | ensure("frand >= 0", (number >= 0.0f)); | 53 | ensure("frand >= 0", (number >= 0.0f)); |
54 | ensure("frand < 1", (number < 1.0f)); | 54 | ensure("frand < 1", (number < 1.0f)); |
55 | } | 55 | } |
56 | } | 56 | } |
57 | 57 | ||
58 | template<> template<> | 58 | template<> template<> |
59 | void random_object_t::test<2>() | 59 | void random_object_t::test<2>() |
60 | { | 60 | { |
61 | F32 number = 0.0f; | 61 | F64 number = 0.0f; |
62 | for(S32 ii = 0; ii < 100000; ++ii) | 62 | for(S32 ii = 0; ii < 100000; ++ii) |
63 | { | 63 | { |
64 | number = ll_frand(2.0f) - 1.0f; | 64 | number = ll_drand(); |
65 | ensure("frand >= 0", (number >= -1.0f)); | 65 | ensure("drand >= 0", (number >= 0.0)); |
66 | ensure("frand < 1", (number <= 1.0f)); | 66 | ensure("drand < 1", (number < 1.0)); |
67 | } | 67 | } |
68 | } | 68 | } |
69 | } | 69 | |
70 | template<> template<> | ||
71 | void random_object_t::test<3>() | ||
72 | { | ||
73 | F32 number = 0.0f; | ||
74 | for(S32 ii = 0; ii < 100000; ++ii) | ||
75 | { | ||
76 | number = ll_frand(2.0f) - 1.0f; | ||
77 | ensure("frand >= 0", (number >= -1.0f)); | ||
78 | ensure("frand < 1", (number <= 1.0f)); | ||
79 | } | ||
80 | } | ||
81 | |||
82 | template<> template<> | ||
83 | void random_object_t::test<4>() | ||
84 | { | ||
85 | F32 number = 0.0f; | ||
86 | for(S32 ii = 0; ii < 100000; ++ii) | ||
87 | { | ||
88 | number = ll_frand(-7.0); | ||
89 | ensure("drand <= 0", (number <= 0.0)); | ||
90 | ensure("drand > -7", (number > -7.0)); | ||
91 | } | ||
92 | } | ||
93 | |||
94 | template<> template<> | ||
95 | void random_object_t::test<5>() | ||
96 | { | ||
97 | F64 number = 0.0f; | ||
98 | for(S32 ii = 0; ii < 100000; ++ii) | ||
99 | { | ||
100 | number = ll_drand(-2.0); | ||
101 | ensure("drand <= 0", (number <= 0.0)); | ||
102 | ensure("drand > -2", (number > -2.0)); | ||
103 | } | ||
104 | } | ||
105 | |||
106 | template<> template<> | ||
107 | void random_object_t::test<6>() | ||
108 | { | ||
109 | S32 number = 0; | ||
110 | for(S32 ii = 0; ii < 100000; ++ii) | ||
111 | { | ||
112 | number = ll_rand(100); | ||
113 | ensure("rand >= 0", (number >= 0)); | ||
114 | ensure("rand < 100", (number < 100)); | ||
115 | } | ||
116 | } | ||
117 | |||
118 | template<> template<> | ||
119 | void random_object_t::test<7>() | ||
120 | { | ||
121 | S32 number = 0; | ||
122 | for(S32 ii = 0; ii < 100000; ++ii) | ||
123 | { | ||
124 | number = ll_rand(-127); | ||
125 | ensure("rand <= 0", (number <= 0)); | ||
126 | ensure("rand > -127", (number > -127)); | ||
127 | } | ||
128 | } | ||
129 | } | ||
diff --git a/linden/indra/test/llsd_message_system_tut.cpp b/linden/indra/test/llsd_message_system_tut.cpp index b46701c..9fcc6b5 100644 --- a/linden/indra/test/llsd_message_system_tut.cpp +++ b/linden/indra/test/llsd_message_system_tut.cpp | |||
@@ -1,8 +1,8 @@ | |||
1 | /** | 1 | /** |
2 | * @file llsd_message_system_tut.cpp | 2 | * @file llsd_message_system_tut.cpp |
3 | * @brief Testing the LLSDMessageSystem. | 3 | * @brief Testing the LLSDMessageSystem. |
4 | * | 4 | * |
5 | * Copyright (c) 2006-2007, Linden Research, Inc. | 5 | * Copyright (c) 2006-2007, Linden Research, Inc. |
6 | * | 6 | * |
7 | * The source code in this file ("Source Code") is provided by Linden Lab | 7 | * The source code in this file ("Source Code") is provided by Linden Lab |
8 | * to you under the terms of the GNU General Public License, version 2.0 | 8 | * to you under the terms of the GNU General Public License, version 2.0 |
@@ -22,121 +22,123 @@ | |||
22 | * | 22 | * |
23 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | 23 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO |
24 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | 24 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, |
25 | * COMPLETENESS OR PERFORMANCE. | 25 | * COMPLETENESS OR PERFORMANCE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | /** | 28 | /** |
29 | * | 29 | * |
30 | * These classes test the LLSDMessageSystem. | 30 | * These classes test the LLSDMessageSystem. |
31 | * | 31 | * |
32 | */ | 32 | */ |
33 | 33 | ||
34 | #include <tut/tut.h> | 34 | #include "linden_common.h" |
35 | #include "llsdmessagesystem.h" | 35 | |
36 | #include "llsdutil.h" | 36 | #include <tut/tut.h> |
37 | 37 | #include "llsdmessagesystem.h" | |
38 | namespace tut | 38 | #include "llsdutil.h" |
39 | { | 39 | |
40 | class LLSDMessageSystemTestData | 40 | namespace tut |
41 | { | 41 | { |
42 | public: | 42 | class LLSDMessageSystemTestData |
43 | LLSDMessageSystemTestData() {;} | 43 | { |
44 | ~LLSDMessageSystemTestData() {;} | 44 | public: |
45 | 45 | LLSDMessageSystemTestData() {;} | |
46 | LLSDMessageSystem mMsgSystem; | 46 | ~LLSDMessageSystemTestData() {;} |
47 | }; | 47 | |
48 | 48 | LLSDMessageSystem mMsgSystem; | |
49 | typedef test_group<LLSDMessageSystemTestData> LLSDMessageSystemTestGroup; | 49 | }; |
50 | typedef LLSDMessageSystemTestGroup::object LLSDMessageSystemTestObject; | 50 | |
51 | LLSDMessageSystemTestGroup llsdMessageSystemTestGroup("llsd_message_system"); | 51 | typedef test_group<LLSDMessageSystemTestData> LLSDMessageSystemTestGroup; |
52 | 52 | typedef LLSDMessageSystemTestGroup::object LLSDMessageSystemTestObject; | |
53 | template<> template<> | 53 | LLSDMessageSystemTestGroup llsdMessageSystemTestGroup("llsd_message_system"); |
54 | void LLSDMessageSystemTestObject::test<1>() | 54 | |
55 | { | 55 | template<> template<> |
56 | LLSD input; | 56 | void LLSDMessageSystemTestObject::test<1>() |
57 | U32 valueIn, valueOut; | 57 | { |
58 | valueIn = 42; | 58 | LLSD input; |
59 | input["Block"]["Var"] = ll_sd_from_U32(valueIn); | 59 | U32 valueIn, valueOut; |
60 | mMsgSystem.setInput(input); | 60 | valueIn = 42; |
61 | mMsgSystem.getU32Fast("Block", "Var", valueOut); | 61 | input["Block"]["Var"] = ll_sd_from_U32(valueIn); |
62 | ensure_equals("U32 from message system matches input U32", valueIn, valueOut); | 62 | mMsgSystem.setInput(input); |
63 | } | 63 | mMsgSystem.getU32Fast("Block", "Var", valueOut); |
64 | 64 | ensure_equals("U32 from message system matches input U32", valueIn, valueOut); | |
65 | template<> template<> | 65 | } |
66 | void LLSDMessageSystemTestObject::test<2>() | 66 | |
67 | { | 67 | template<> template<> |
68 | LLSD input; | 68 | void LLSDMessageSystemTestObject::test<2>() |
69 | LLUUID valueIn, valueOut; | 69 | { |
70 | valueIn.generate(); | 70 | LLSD input; |
71 | input["Block"]["Var"] = valueIn; | 71 | LLUUID valueIn, valueOut; |
72 | mMsgSystem.setInput(input); | 72 | valueIn.generate(); |
73 | mMsgSystem.getUUIDFast("Block", "Var", valueOut); | 73 | input["Block"]["Var"] = valueIn; |
74 | ensure_equals("UUID from message system matches input UUID", valueIn, valueOut); | 74 | mMsgSystem.setInput(input); |
75 | } | 75 | mMsgSystem.getUUIDFast("Block", "Var", valueOut); |
76 | 76 | ensure_equals("UUID from message system matches input UUID", valueIn, valueOut); | |
77 | template<> template<> | 77 | } |
78 | void LLSDMessageSystemTestObject::test<3>() | 78 | |
79 | { | 79 | template<> template<> |
80 | LLSD input; | 80 | void LLSDMessageSystemTestObject::test<3>() |
81 | U32 valueIn, valueOut; | 81 | { |
82 | LLHost host("127.0.0.1:80"); | 82 | LLSD input; |
83 | valueIn = host.getAddress(); | 83 | U32 valueIn, valueOut; |
84 | input["Block"]["Var"] = ll_sd_from_U32(valueIn); | 84 | LLHost host("127.0.0.1:80"); |
85 | mMsgSystem.setInput(input); | 85 | valueIn = host.getAddress(); |
86 | mMsgSystem.getIPAddrFast("Block", "Var", valueOut); | 86 | input["Block"]["Var"] = ll_sd_from_U32(valueIn); |
87 | ensure_equals("IP from message system matches input IP", valueIn, valueOut); | 87 | mMsgSystem.setInput(input); |
88 | } | 88 | mMsgSystem.getIPAddrFast("Block", "Var", valueOut); |
89 | 89 | ensure_equals("IP from message system matches input IP", valueIn, valueOut); | |
90 | template<> template<> | 90 | } |
91 | void LLSDMessageSystemTestObject::test<4>() | 91 | |
92 | { | 92 | template<> template<> |
93 | LLSD input; | 93 | void LLSDMessageSystemTestObject::test<4>() |
94 | U16 valueIn, valueOut; | 94 | { |
95 | LLHost host("127.0.0.1:80"); | 95 | LLSD input; |
96 | valueIn = host.getPort(); | 96 | U16 valueIn, valueOut; |
97 | input["Block"]["Var"] = (S32)valueIn; | 97 | LLHost host("127.0.0.1:80"); |
98 | mMsgSystem.setInput(input); | 98 | valueIn = host.getPort(); |
99 | mMsgSystem.getIPPortFast("Block", "Var", valueOut); | 99 | input["Block"]["Var"] = (S32)valueIn; |
100 | ensure_equals("Port from message system matches input port", valueIn, valueOut); | 100 | mMsgSystem.setInput(input); |
101 | } | 101 | mMsgSystem.getIPPortFast("Block", "Var", valueOut); |
102 | 102 | ensure_equals("Port from message system matches input port", valueIn, valueOut); | |
103 | template<> template<> | 103 | } |
104 | void LLSDMessageSystemTestObject::test<5>() | 104 | |
105 | { | 105 | template<> template<> |
106 | LLSD input; | 106 | void LLSDMessageSystemTestObject::test<5>() |
107 | U64 valueIn, valueOut; | 107 | { |
108 | valueIn = 42; | 108 | LLSD input; |
109 | input["Block"]["Var"] = ll_sd_from_U64(valueIn); | 109 | U64 valueIn, valueOut; |
110 | mMsgSystem.setInput(input); | 110 | valueIn = 42; |
111 | mMsgSystem.getU64Fast("Block", "Var", valueOut); | 111 | input["Block"]["Var"] = ll_sd_from_U64(valueIn); |
112 | ensure_equals("Port from message system matches input port", valueIn, valueOut); | 112 | mMsgSystem.setInput(input); |
113 | } | 113 | mMsgSystem.getU64Fast("Block", "Var", valueOut); |
114 | 114 | ensure_equals("Port from message system matches input port", valueIn, valueOut); | |
115 | template<> template<> | 115 | } |
116 | void LLSDMessageSystemTestObject::test<6>() | 116 | |
117 | { | 117 | template<> template<> |
118 | LLSD input; | 118 | void LLSDMessageSystemTestObject::test<6>() |
119 | std::string valueIn = "Value"; | 119 | { |
120 | input["Block"]["Var"] = valueIn; | 120 | LLSD input; |
121 | mMsgSystem.setInput(input); | 121 | std::string valueIn = "Value"; |
122 | const U32 buffLen = 16; | 122 | input["Block"]["Var"] = valueIn; |
123 | char buff[buffLen]; | 123 | mMsgSystem.setInput(input); |
124 | mMsgSystem.getStringFast("Block", "Var", buffLen, buff); | 124 | const U32 buffLen = 16; |
125 | ensure_equals("string read from message system matches llsd input", std::string(buff), valueIn); | 125 | char buff[buffLen]; |
126 | } | 126 | mMsgSystem.getStringFast("Block", "Var", buffLen, buff); |
127 | 127 | ensure_equals("string read from message system matches llsd input", std::string(buff), valueIn); | |
128 | template<> template<> | 128 | } |
129 | void LLSDMessageSystemTestObject::test<7>() | 129 | |
130 | { | 130 | template<> template<> |
131 | LLSD input; | 131 | void LLSDMessageSystemTestObject::test<7>() |
132 | U32 valueIn, valueOut; | 132 | { |
133 | valueIn = 42; | 133 | LLSD input; |
134 | input["Block"][0]["Var"] = ll_sd_from_U32(valueIn); | 134 | U32 valueIn, valueOut; |
135 | input["Block"][1]["Var"] = ll_sd_from_U32(valueIn + 1); | 135 | valueIn = 42; |
136 | mMsgSystem.setInput(input); | 136 | input["Block"][0]["Var"] = ll_sd_from_U32(valueIn); |
137 | mMsgSystem.getU32Fast("Block", "Var", valueOut, 0); | 137 | input["Block"][1]["Var"] = ll_sd_from_U32(valueIn + 1); |
138 | ensure_equals("U32 from message system matches input U32", valueIn, valueOut); | 138 | mMsgSystem.setInput(input); |
139 | mMsgSystem.getU32Fast("Block", "Var", valueOut, 1); | 139 | mMsgSystem.getU32Fast("Block", "Var", valueOut, 0); |
140 | ensure_equals("U32 from message system matches input U32", (valueIn + 1), valueOut); | 140 | ensure_equals("U32 from message system matches input U32", valueIn, valueOut); |
141 | } | 141 | mMsgSystem.getU32Fast("Block", "Var", valueOut, 1); |
142 | } | 142 | ensure_equals("U32 from message system matches input U32", (valueIn + 1), valueOut); |
143 | } | ||
144 | } | ||
diff --git a/linden/indra/test/llsd_new_tut.cpp b/linden/indra/test/llsd_new_tut.cpp index e33a28a..d278a78 100644 --- a/linden/indra/test/llsd_new_tut.cpp +++ b/linden/indra/test/llsd_new_tut.cpp | |||
@@ -28,9 +28,11 @@ | |||
28 | 28 | ||
29 | #include <math.h> | 29 | #include <math.h> |
30 | #include <tut/tut.h> | 30 | #include <tut/tut.h> |
31 | #include "linden_common.h" | ||
31 | #include "lltut.h" | 32 | #include "lltut.h" |
32 | 33 | ||
33 | #include "llsd.h" | 34 | #include "llsd.h" |
35 | #include "llstring.h" | ||
34 | 36 | ||
35 | namespace tut | 37 | namespace tut |
36 | { | 38 | { |
diff --git a/linden/indra/test/lltut.cpp b/linden/indra/test/lltut.cpp index 31b83e6..1127f72 100644 --- a/linden/indra/test/lltut.cpp +++ b/linden/indra/test/lltut.cpp | |||
@@ -27,7 +27,10 @@ | |||
27 | * COMPLETENESS OR PERFORMANCE. | 27 | * COMPLETENESS OR PERFORMANCE. |
28 | */ | 28 | */ |
29 | 29 | ||
30 | #include "linden_common.h" | ||
30 | #include "lltut.h" | 31 | #include "lltut.h" |
32 | |||
33 | #include "llformat.h" | ||
31 | #include "llsd.h" | 34 | #include "llsd.h" |
32 | 35 | ||
33 | namespace tut | 36 | namespace tut |
@@ -154,6 +157,20 @@ namespace tut | |||
154 | } | 157 | } |
155 | } | 158 | } |
156 | 159 | ||
160 | void ensure_ends_with(const std::string& msg, | ||
161 | const std::string& actual, const std::string& expectedEnd) | ||
162 | { | ||
163 | if( actual.size() < expectedEnd.size() | ||
164 | || actual.rfind(expectedEnd) | ||
165 | != (actual.size() - expectedEnd.size()) ) | ||
166 | { | ||
167 | std::stringstream ss; | ||
168 | ss << msg << ": " << "expected to find " << expectedEnd | ||
169 | << " at end of actual " << actual; | ||
170 | throw failure(ss.str().c_str()); | ||
171 | } | ||
172 | } | ||
173 | |||
157 | void ensure_contains(const std::string& msg, | 174 | void ensure_contains(const std::string& msg, |
158 | const std::string& actual, const std::string& expectedSubString) | 175 | const std::string& actual, const std::string& expectedSubString) |
159 | { | 176 | { |
@@ -165,4 +182,16 @@ namespace tut | |||
165 | throw failure(ss.str().c_str()); | 182 | throw failure(ss.str().c_str()); |
166 | } | 183 | } |
167 | } | 184 | } |
185 | |||
186 | void ensure_does_not_contain(const std::string& msg, | ||
187 | const std::string& actual, const std::string& expectedSubString) | ||
188 | { | ||
189 | if( actual.find(expectedSubString, 0) != std::string::npos ) | ||
190 | { | ||
191 | std::stringstream ss; | ||
192 | ss << msg << ": " << "expected not to find " << expectedSubString | ||
193 | << " in actual " << actual; | ||
194 | throw failure(ss.str().c_str()); | ||
195 | } | ||
196 | } | ||
168 | } | 197 | } |
diff --git a/linden/indra/test/lltut.h b/linden/indra/test/lltut.h index ba3df24..c8fb6bc 100644 --- a/linden/indra/test/lltut.h +++ b/linden/indra/test/lltut.h | |||
@@ -87,8 +87,14 @@ namespace tut | |||
87 | void ensure_starts_with(const std::string& msg, | 87 | void ensure_starts_with(const std::string& msg, |
88 | const std::string& actual, const std::string& expectedStart); | 88 | const std::string& actual, const std::string& expectedStart); |
89 | 89 | ||
90 | void ensure_ends_with(const std::string& msg, | ||
91 | const std::string& actual, const std::string& expectedEnd); | ||
92 | |||
90 | void ensure_contains(const std::string& msg, | 93 | void ensure_contains(const std::string& msg, |
91 | const std::string& actual, const std::string& expectedSubString); | 94 | const std::string& actual, const std::string& expectedSubString); |
95 | |||
96 | void ensure_does_not_contain(const std::string& msg, | ||
97 | const std::string& actual, const std::string& expectedSubString); | ||
92 | } | 98 | } |
93 | 99 | ||
94 | 100 | ||
diff --git a/linden/indra/test/lluri_tut.cpp b/linden/indra/test/lluri_tut.cpp index acd67cf..31ea7d6 100644 --- a/linden/indra/test/lluri_tut.cpp +++ b/linden/indra/test/lluri_tut.cpp | |||
@@ -36,51 +36,19 @@ | |||
36 | namespace tut | 36 | namespace tut |
37 | { | 37 | { |
38 | struct URITestData { | 38 | struct URITestData { |
39 | void checkParts(const std::string& uriString, | 39 | void checkParts(const LLURI& u, |
40 | const char* expectedScheme, | 40 | const char* expectedScheme, |
41 | const char* expectedOpaque, | 41 | const char* expectedOpaque, |
42 | const char* expectedAuthority, | 42 | const char* expectedAuthority, |
43 | const char* expectedPath, | 43 | const char* expectedPath, |
44 | const char* expectedQuery) | 44 | const char* expectedQuery = "") |
45 | { | 45 | { |
46 | LLURI u(uriString); | ||
47 | |||
48 | ensure_equals("scheme", u.scheme(), expectedScheme); | 46 | ensure_equals("scheme", u.scheme(), expectedScheme); |
49 | ensure_equals("opaque", u.opaque(), expectedOpaque); | 47 | ensure_equals("opaque", u.opaque(), expectedOpaque); |
50 | ensure_equals("authority", u.authority(), expectedAuthority); | 48 | ensure_equals("authority", u.authority(), expectedAuthority); |
51 | ensure_equals("path", u.path(), expectedPath); | 49 | ensure_equals("path", u.path(), expectedPath); |
52 | ensure_equals("query", u.query(), expectedQuery); | 50 | ensure_equals("query", u.query(), expectedQuery); |
53 | } | 51 | } |
54 | |||
55 | void checkPartsHTTP(const char* host_and_port, | ||
56 | const LLSD& path, | ||
57 | const char* expectedOpaque, | ||
58 | const char* expectedAuthority, | ||
59 | const char* expectedPath) | ||
60 | { | ||
61 | LLURI u = LLURI::buildHTTP(host_and_port, path); | ||
62 | ensure_equals("scheme", u.scheme(), "HTTP"); | ||
63 | ensure_equals("opaque", u.opaque(), expectedOpaque); | ||
64 | ensure_equals("authority", u.authority(), expectedAuthority); | ||
65 | ensure_equals("path", u.path(), expectedPath); | ||
66 | ensure_equals("query", u.query(), ""); | ||
67 | } | ||
68 | |||
69 | void checkPartsHTTP(const char* host_and_port, | ||
70 | const LLSD& path, | ||
71 | const LLSD& args, | ||
72 | const char* expectedOpaque, | ||
73 | const char* expectedAuthority, | ||
74 | const char* expectedPath, | ||
75 | const char* expectedQuery) | ||
76 | { | ||
77 | LLURI u = LLURI::buildHTTP(host_and_port, path, args); | ||
78 | ensure_equals("scheme", u.scheme(), "HTTP"); | ||
79 | ensure_equals("opaque", u.opaque(), expectedOpaque); | ||
80 | ensure_equals("authority", u.authority(), expectedAuthority); | ||
81 | ensure_equals("path", u.path(), expectedPath); | ||
82 | ensure_equals("query", u.query(), expectedQuery); | ||
83 | } | ||
84 | }; | 52 | }; |
85 | 53 | ||
86 | typedef test_group<URITestData> URITestGroup; | 54 | typedef test_group<URITestData> URITestGroup; |
@@ -114,59 +82,73 @@ namespace tut | |||
114 | void URITestObject::test<2>() | 82 | void URITestObject::test<2>() |
115 | { | 83 | { |
116 | // empty string | 84 | // empty string |
117 | checkParts("", "", "", "", "", ""); | 85 | checkParts(LLURI(""), "", "", "", ""); |
118 | } | 86 | } |
119 | 87 | ||
120 | template<> template<> | 88 | template<> template<> |
121 | void URITestObject::test<3>() | 89 | void URITestObject::test<3>() |
122 | { | 90 | { |
123 | // no scheme | 91 | // no scheme |
124 | checkParts("foo", "", "foo", "", "", ""); | 92 | checkParts(LLURI("foo"), "", "foo", "", ""); |
125 | checkParts("foo%3A", "", "foo:", "", "", ""); | 93 | checkParts(LLURI("foo%3A"), "", "foo:", "", ""); |
126 | } | 94 | } |
127 | 95 | ||
128 | template<> template<> | 96 | template<> template<> |
129 | void URITestObject::test<4>() | 97 | void URITestObject::test<4>() |
130 | { | 98 | { |
131 | // scheme w/o paths | 99 | // scheme w/o paths |
132 | checkParts("mailto:zero@ll.com", "mailto", "zero@ll.com", "", "", ""); | 100 | checkParts(LLURI("mailto:zero@ll.com"), |
133 | checkParts("silly://abc/def?foo", "silly", "//abc/def?foo", "", "", ""); | 101 | "mailto", "zero@ll.com", "", ""); |
102 | checkParts(LLURI("silly://abc/def?foo"), | ||
103 | "silly", "//abc/def?foo", "", ""); | ||
134 | } | 104 | } |
135 | 105 | ||
136 | template<> template<> | 106 | template<> template<> |
137 | void URITestObject::test<5>() | 107 | void URITestObject::test<5>() |
138 | { | 108 | { |
139 | // authority section | 109 | // authority section |
140 | checkParts("http:///", "http", "///", "", "/", ""); | 110 | checkParts(LLURI("http:///"), |
141 | checkParts("http://abc", "http", "//abc", "abc", "", ""); | 111 | "http", "///", "", "/"); |
142 | checkParts("http://a%2Fb/cd", "http", "//a/b/cd", "a/b", "/cd", ""); | 112 | |
143 | checkParts("http://host?", "http", "//host?", "host", "", ""); | 113 | checkParts(LLURI("http://abc"), |
114 | "http", "//abc", "abc", ""); | ||
115 | |||
116 | checkParts(LLURI("http://a%2Fb/cd"), | ||
117 | "http", "//a/b/cd", "a/b", "/cd"); | ||
118 | |||
119 | checkParts(LLURI("http://host?"), | ||
120 | "http", "//host?", "host", ""); | ||
144 | } | 121 | } |
145 | 122 | ||
146 | template<> template<> | 123 | template<> template<> |
147 | void URITestObject::test<6>() | 124 | void URITestObject::test<6>() |
148 | { | 125 | { |
149 | // path section | 126 | // path section |
150 | checkParts("http://host/a/b/", "http", "//host/a/b/", | 127 | checkParts(LLURI("http://host/a/b/"), |
151 | "host", "/a/b/", ""); | 128 | "http", "//host/a/b/", "host", "/a/b/"); |
152 | checkParts("http://host/a%3Fb/", "http", "//host/a?b/", | 129 | |
153 | "host", "/a?b/", ""); | 130 | checkParts(LLURI("http://host/a%3Fb/"), |
154 | checkParts("http://host/a:b/", "http", "//host/a:b/", | 131 | "http", "//host/a?b/", "host", "/a?b/"); |
155 | "host", "/a:b/", ""); | 132 | |
133 | checkParts(LLURI("http://host/a:b/"), | ||
134 | "http", "//host/a:b/", "host", "/a:b/"); | ||
156 | } | 135 | } |
157 | 136 | ||
158 | template<> template<> | 137 | template<> template<> |
159 | void URITestObject::test<7>() | 138 | void URITestObject::test<7>() |
160 | { | 139 | { |
161 | // query string | 140 | // query string |
162 | checkParts("http://host/?", "http", "//host/?", | 141 | checkParts(LLURI("http://host/?"), |
163 | "host", "/", ""); | 142 | "http", "//host/?", "host", "/", ""); |
164 | checkParts("http://host/?x", "http", "//host/?x", | 143 | |
165 | "host", "/", "x"); | 144 | checkParts(LLURI("http://host/?x"), |
166 | checkParts("http://host/??", "http", "//host/??", | 145 | "http", "//host/?x", "host", "/", "x"); |
167 | "host", "/", "?"); | 146 | |
168 | checkParts("http://host/?%3F", "http", "//host/??", | 147 | checkParts(LLURI("http://host/??"), |
169 | "host", "/", "?"); | 148 | "http", "//host/??", "host", "/", "?"); |
149 | |||
150 | checkParts(LLURI("http://host/?%3F"), | ||
151 | "http", "//host/??", "host", "/", "?"); | ||
170 | } | 152 | } |
171 | 153 | ||
172 | template<> template<> | 154 | template<> template<> |
@@ -175,11 +157,15 @@ namespace tut | |||
175 | LLSD path; | 157 | LLSD path; |
176 | path.append("x"); | 158 | path.append("x"); |
177 | path.append("123"); | 159 | path.append("123"); |
178 | checkPartsHTTP("host", path, "//host/x/123", "//host", "/x/123"); | 160 | checkParts(LLURI::buildHTTP("host", path), |
161 | "http", "//host/x/123", "host", "/x/123"); | ||
162 | |||
179 | LLSD query; | 163 | LLSD query; |
180 | query["123"] = "12"; | 164 | query["123"] = "12"; |
181 | query["abcd"] = "abc"; | 165 | query["abcd"] = "abc"; |
182 | checkPartsHTTP("host", path, query, "//host/x/123?123=12&abcd=abc&", "//host", "/x/123", "123=12&abcd=abc&"); | 166 | checkParts(LLURI::buildHTTP("host", path, query), |
167 | "http", "//host/x/123?123=12&abcd=abc&", | ||
168 | "host", "/x/123", "123=12&abcd=abc&"); | ||
183 | } | 169 | } |
184 | 170 | ||
185 | template<> template<> | 171 | template<> template<> |
@@ -189,7 +175,8 @@ namespace tut | |||
189 | LLSD path; | 175 | LLSD path; |
190 | path.append("x@*//*$&^"); | 176 | path.append("x@*//*$&^"); |
191 | path.append("123"); | 177 | path.append("123"); |
192 | checkPartsHTTP("host", path, "//host/x@*//*$&^/123", "//host", "/x@*//*$&^/123"); | 178 | checkParts(LLURI::buildHTTP("host", path), |
179 | "http", "//host/x@*//*$&^/123", "host", "/x@*//*$&^/123"); | ||
193 | } | 180 | } |
194 | 181 | ||
195 | template<> template<> | 182 | template<> template<> |
@@ -202,7 +189,9 @@ namespace tut | |||
202 | LLSD query; | 189 | LLSD query; |
203 | query["123"] = "?&*#//"; | 190 | query["123"] = "?&*#//"; |
204 | query["**@&?//"] = "abc"; | 191 | query["**@&?//"] = "abc"; |
205 | checkPartsHTTP("host", path, query, "//host/x/123?**@&?//=abc&123=?&*#//&", "//host", "/x/123", "**@&?//=abc&123=?&*#//&"); | 192 | checkParts(LLURI::buildHTTP("host", path, query), |
193 | "http", "//host/x/123?**@&?//=abc&123=?&*#//&", | ||
194 | "host", "/x/123", "**@&?//=abc&123=?&*#//&"); | ||
206 | } | 195 | } |
207 | 196 | ||
208 | template<> template<> | 197 | template<> template<> |
@@ -215,7 +204,67 @@ namespace tut | |||
215 | LLSD query; | 204 | LLSD query; |
216 | query["123"] = "12"; | 205 | query["123"] = "12"; |
217 | query["abcd"] = "abc"; | 206 | query["abcd"] = "abc"; |
218 | checkPartsHTTP("hi123*33--}{:portstuffs", path, query, "//hi123*33--}{:portstuffs/x/123?123=12&abcd=abc&", "//hi123*33--}{:portstuffs", "/x/123", "123=12&abcd=abc&"); | 207 | checkParts(LLURI::buildHTTP("hi123*33--}{:portstuffs", path, query), |
208 | "http", "//hi123*33--}{:portstuffs/x/123?123=12&abcd=abc&", | ||
209 | "hi123*33--}{:portstuffs", "/x/123", "123=12&abcd=abc&"); | ||
210 | } | ||
211 | |||
212 | template<> template<> | ||
213 | void URITestObject::test<12>() | ||
214 | { | ||
215 | // test funky host_port values that are actually prefixes | ||
216 | |||
217 | checkParts(LLURI::buildHTTP("http://example.com:8080", LLSD()), | ||
218 | "http", "//example.com:8080", | ||
219 | "example.com:8080", ""); | ||
220 | |||
221 | checkParts(LLURI::buildHTTP("http://example.com:8080/", LLSD()), | ||
222 | "http", "//example.com:8080/", | ||
223 | "example.com:8080", "/"); | ||
224 | |||
225 | checkParts(LLURI::buildHTTP("http://example.com:8080/a/b", LLSD()), | ||
226 | "http", "//example.com:8080/a/b", | ||
227 | "example.com:8080", "/a/b"); | ||
228 | } | ||
229 | |||
230 | template<> template<> | ||
231 | void URITestObject::test<13>() | ||
232 | { | ||
233 | const std::string unreserved = | ||
234 | "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz" | ||
235 | "0123456789" | ||
236 | "-._~"; | ||
237 | // test escape | ||
238 | ensure_equals("escaping", LLURI::escape("abcdefg", "abcdef"), "abcdef%67"); | ||
239 | ensure_equals("escaping", LLURI::escape("|/&\\+-_!@", ""), "%7C%2F%26%5C%2B%2D%5F%21%40"); | ||
240 | ensure_equals("escaping as query variable", | ||
241 | LLURI::escape("http://10.0.1.4:12032/agent/god/agent-id/map/layer/?resume=http://station3.ll.com:12032/agent/203ad6df-b522-491d-ba48-4e24eb57aeff/send-postcard", unreserved + ":@!$'()*+,="), | ||
242 | "http:%2F%2F10.0.1.4:12032%2Fagent%2Fgod%2Fagent-id%2Fmap%2Flayer%2F%3Fresume=http:%2F%2Fstation3.ll.com:12032%2Fagent%2F203ad6df-b522-491d-ba48-4e24eb57aeff%2Fsend-postcard"); | ||
243 | } | ||
244 | |||
245 | template<> template<> | ||
246 | void URITestObject::test<14>() | ||
247 | { | ||
248 | // test various build utilities | ||
249 | |||
250 | LLUUID id("11111111-2222-3333-4444-5566778899aa"); | ||
251 | |||
252 | |||
253 | checkParts(LLURI::buildAgentPresenceURI(id, NULL), | ||
254 | "http", "//localhost:12040/agent/11111111-2222-3333-4444-5566778899aa/presence", | ||
255 | "localhost:12040", "/agent/11111111-2222-3333-4444-5566778899aa/presence"); | ||
256 | |||
257 | checkParts(LLURI::buildBulkAgentPresenceURI(NULL), | ||
258 | "http", "//localhost:12040/agent/presence", | ||
259 | "localhost:12040", "/agent/presence"); | ||
260 | |||
261 | checkParts(LLURI::buildAgentSessionURI(id, NULL), | ||
262 | "http", "//localhost:12040/agent/11111111-2222-3333-4444-5566778899aa/session", | ||
263 | "localhost:12040", "/agent/11111111-2222-3333-4444-5566778899aa/session"); | ||
264 | |||
265 | checkParts(LLURI::buildAgentLoginInfoURI(id, "datasever:12345"), | ||
266 | "http", "//datasever:12345/agent/11111111-2222-3333-4444-5566778899aa/logininfo", | ||
267 | "datasever:12345", "/agent/11111111-2222-3333-4444-5566778899aa/logininfo"); | ||
219 | } | 268 | } |
220 | } | 269 | } |
221 | 270 | ||
diff --git a/linden/indra/test/math.cpp b/linden/indra/test/math.cpp index b14a798..be8a398 100644 --- a/linden/indra/test/math.cpp +++ b/linden/indra/test/math.cpp | |||
@@ -125,7 +125,7 @@ namespace tut | |||
125 | void uuid_object::test<4>() | 125 | void uuid_object::test<4>() |
126 | { | 126 | { |
127 | id.generate(); | 127 | id.generate(); |
128 | LLString id_str = id.getString(); | 128 | std::string id_str = id.asString(); |
129 | LLUUID copy(id_str.c_str()); | 129 | LLUUID copy(id_str.c_str()); |
130 | ensure_equals("string serialization", id, copy); | 130 | ensure_equals("string serialization", id, copy); |
131 | } | 131 | } |
diff --git a/linden/indra/test/test.cpp b/linden/indra/test/test.cpp index d90bfdb..9eb1639 100644 --- a/linden/indra/test/test.cpp +++ b/linden/indra/test/test.cpp | |||
@@ -36,6 +36,7 @@ | |||
36 | */ | 36 | */ |
37 | 37 | ||
38 | #include "linden_common.h" | 38 | #include "linden_common.h" |
39 | #include "llerrorcontrol.h" | ||
39 | #include "lltut.h" | 40 | #include "lltut.h" |
40 | 41 | ||
41 | #include <apr-1/apr_pools.h> | 42 | #include <apr-1/apr_pools.h> |
@@ -178,8 +179,18 @@ void stream_groups(std::ostream& s, const char* app) | |||
178 | } | 179 | } |
179 | } | 180 | } |
180 | 181 | ||
182 | void wouldHaveCrashed(const std::string& message) | ||
183 | { | ||
184 | tut::fail("llerrs message: " + message); | ||
185 | } | ||
186 | |||
181 | int main(int argc, char **argv) | 187 | int main(int argc, char **argv) |
182 | { | 188 | { |
189 | LLError::initForApplication("."); | ||
190 | LLError::setFatalFunction(wouldHaveCrashed); | ||
191 | LLError::setDefaultLevel(LLError::LEVEL_ERROR); | ||
192 | // *FIX: should come from error config file | ||
193 | |||
183 | #ifdef CTYPE_WORKAROUND | 194 | #ifdef CTYPE_WORKAROUND |
184 | ctype_workaround(); | 195 | ctype_workaround(); |
185 | #endif | 196 | #endif |
@@ -213,7 +224,7 @@ int main(int argc, char **argv) | |||
213 | if(APR_STATUS_IS_EOF(apr_err)) break; | 224 | if(APR_STATUS_IS_EOF(apr_err)) break; |
214 | if(apr_err) | 225 | if(apr_err) |
215 | { | 226 | { |
216 | char buf[255]; | 227 | char buf[255]; /* Flawfinder: ignore */ |
217 | std::cerr << "Error parsing options: " | 228 | std::cerr << "Error parsing options: " |
218 | << apr_strerror(apr_err, buf, 255) << std::endl; | 229 | << apr_strerror(apr_err, buf, 255) << std::endl; |
219 | return 1; | 230 | return 1; |
diff --git a/linden/indra/test/test.vcproj b/linden/indra/test/test.vcproj index f07d412..9255315 100644 --- a/linden/indra/test/test.vcproj +++ b/linden/indra/test/test.vcproj | |||
@@ -195,6 +195,9 @@ | |||
195 | </File> | 195 | </File> |
196 | 196 | ||
197 | <File | 197 | <File |
198 | RelativePath=".\llerror_tut.cpp"> | ||
199 | </File> | ||
200 | <File | ||
198 | RelativePath=".\llhttpclient_tut.cpp"> | 201 | RelativePath=".\llhttpclient_tut.cpp"> |
199 | </File> | 202 | </File> |
200 | <File | 203 | <File |
@@ -216,9 +219,18 @@ | |||
216 | RelativePath=".\llsdserialize_tut.cpp"> | 219 | RelativePath=".\llsdserialize_tut.cpp"> |
217 | </File> | 220 | </File> |
218 | <File | 221 | <File |
222 | RelativePath=".\lltiming_tut.cpp"> | ||
223 | </File> | ||
224 | <File | ||
219 | RelativePath=".\lltut.cpp"> | 225 | RelativePath=".\lltut.cpp"> |
220 | </File> | 226 | </File> |
221 | <File | 227 | <File |
228 | RelativePath=".\lluri_tut.cpp"> | ||
229 | </File> | ||
230 | <File | ||
231 | RelativePath=".\lluserrelations_tut.cpp"> | ||
232 | </File> | ||
233 | <File | ||
222 | RelativePath=".\math.cpp"> | 234 | RelativePath=".\math.cpp"> |
223 | </File> | 235 | </File> |
224 | <File | 236 | <File |
@@ -233,6 +245,9 @@ | |||
233 | Filter="h;hpp;hxx;hm;inl;inc;xsd" | 245 | Filter="h;hpp;hxx;hm;inl;inc;xsd" |
234 | UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"> | 246 | UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"> |
235 | <File | 247 | <File |
248 | RelativePath=".\llpipeutil.h"> | ||
249 | </File> | ||
250 | <File | ||
236 | RelativePath=".\lltut.h"> | 251 | RelativePath=".\lltut.h"> |
237 | </File> | 252 | </File> |
238 | </Filter> | 253 | </Filter> |
diff --git a/linden/indra/test/test_llmanifest.py b/linden/indra/test/test_llmanifest.py new file mode 100644 index 0000000..b20b6c1 --- /dev/null +++ b/linden/indra/test/test_llmanifest.py | |||
@@ -0,0 +1,128 @@ | |||
1 | #!/usr/bin/python | ||
2 | # @file test_llmanifest.py | ||
3 | # @author Ryan Williams | ||
4 | # @brief Test cases for LLManifest library. | ||
5 | # | ||
6 | # Copyright (c) 2006-2007, Linden Research, Inc. | ||
7 | # | ||
8 | # The source code in this file ("Source Code") is provided by Linden Lab | ||
9 | # to you under the terms of the GNU General Public License, version 2.0 | ||
10 | # ("GPL"), unless you have obtained a separate licensing agreement | ||
11 | # ("Other License"), formally executed by you and Linden Lab. Terms of | ||
12 | # the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
13 | # online at http://secondlife.com/developers/opensource/gplv2 | ||
14 | # | ||
15 | # There are special exceptions to the terms and conditions of the GPL as | ||
16 | # it is applied to this Source Code. View the full text of the exception | ||
17 | # in the file doc/FLOSS-exception.txt in this software distribution, or | ||
18 | # online at http://secondlife.com/developers/opensource/flossexception | ||
19 | # | ||
20 | # By copying, modifying or distributing this software, you acknowledge | ||
21 | # that you have read and understood your obligations described above, | ||
22 | # and agree to abide by those obligations. | ||
23 | # | ||
24 | # ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
25 | # WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
26 | # COMPLETENESS OR PERFORMANCE. | ||
27 | |||
28 | from indra import llmanifest | ||
29 | import os.path | ||
30 | import os | ||
31 | import unittest | ||
32 | |||
33 | class DemoManifest(llmanifest.LLManifest): | ||
34 | def construct(self): | ||
35 | super(DemoManifest, self).construct() | ||
36 | if self.prefix("dir_1"): | ||
37 | self.path("test_a") | ||
38 | self.path(src="test_b", dst="test_dst_b") | ||
39 | self.path("*.test") | ||
40 | self.path("*.tex", "*.jpg") | ||
41 | if self.prefix("nested", dst=""): | ||
42 | self.path("deep") | ||
43 | self.end_prefix() | ||
44 | self.end_prefix("dir_1") | ||
45 | |||
46 | |||
47 | class Demo_ArchManifest(llmanifest.LLManifest): | ||
48 | pass | ||
49 | |||
50 | class TestLLManifest(unittest.TestCase): | ||
51 | mode='static' | ||
52 | def setUp(self): | ||
53 | self.m = llmanifest.LLManifest("src", "dst", {'grid':'default', 'platform':'darwin', 'version':(1,2,3,4)}) | ||
54 | |||
55 | def testproperwindowspath(self): | ||
56 | self.assertEqual(llmanifest.proper_windows_path("C:\Program Files", "cygwin"),"/cygdrive/c/Program Files") | ||
57 | self.assertEqual(llmanifest.proper_windows_path("C:\Program Files", "windows"), "C:\Program Files") | ||
58 | self.assertEqual(llmanifest.proper_windows_path("/cygdrive/c/Program Files/NSIS", "windows"), "C:\Program Files\NSIS") | ||
59 | self.assertEqual(llmanifest.proper_windows_path("/cygdrive/c/Program Files/NSIS", "cygwin"), "/cygdrive/c/Program Files/NSIS") | ||
60 | |||
61 | def testpathancestors(self): | ||
62 | self.assertEqual(["dir"], [p for p in llmanifest.path_ancestors("dir")]) | ||
63 | self.assertEqual(["dir/sub", "dir"], [p for p in llmanifest.path_ancestors("dir/sub")]) | ||
64 | self.assertEqual(["dir/sub", "dir"], [p for p in llmanifest.path_ancestors("dir/sub/")]) | ||
65 | self.assertEqual(["dir/sub/two", "dir/sub", "dir"], [p for p in llmanifest.path_ancestors("dir/sub/two")]) | ||
66 | |||
67 | |||
68 | def testforplatform(self): | ||
69 | self.assertEqual(llmanifest.LLManifest.for_platform('demo'), DemoManifest) | ||
70 | def tmp_test(): | ||
71 | return llmanifest.LLManifest.for_platform('extant') | ||
72 | self.assertRaises(KeyError, tmp_test) | ||
73 | ExtantManifest = llmanifest.LLManifestRegistry('ExtantManifest', (llmanifest.LLManifest,), {}) | ||
74 | self.assertEqual(llmanifest.LLManifest.for_platform('extant'), ExtantManifest) | ||
75 | self.assertEqual(llmanifest.LLManifest.for_platform('demo', 'Arch'), Demo_ArchManifest) | ||
76 | |||
77 | |||
78 | def testprefix(self): | ||
79 | self.assertEqual(self.m.get_src_prefix(), "src") | ||
80 | self.assertEqual(self.m.get_dst_prefix(), "dst") | ||
81 | self.m.prefix("level1") | ||
82 | self.assertEqual(self.m.get_src_prefix(), "src/level1") | ||
83 | self.assertEqual(self.m.get_dst_prefix(), "dst/level1") | ||
84 | self.m.end_prefix() | ||
85 | self.m.prefix(src="src", dst="dst") | ||
86 | self.assertEqual(self.m.get_src_prefix(), "src/src") | ||
87 | self.assertEqual(self.m.get_dst_prefix(), "dst/dst") | ||
88 | self.m.end_prefix() | ||
89 | |||
90 | def testendprefix(self): | ||
91 | self.assertEqual(self.m.get_src_prefix(), "src") | ||
92 | self.assertEqual(self.m.get_dst_prefix(), "dst") | ||
93 | self.m.prefix("levela") | ||
94 | self.m.end_prefix() | ||
95 | self.assertEqual(self.m.get_src_prefix(), "src") | ||
96 | self.assertEqual(self.m.get_dst_prefix(), "dst") | ||
97 | self.m.prefix("level1") | ||
98 | self.m.end_prefix("level1") | ||
99 | self.assertEqual(self.m.get_src_prefix(), "src") | ||
100 | self.assertEqual(self.m.get_dst_prefix(), "dst") | ||
101 | self.m.prefix("level1") | ||
102 | def tmp_test(): | ||
103 | self.m.end_prefix("mismatch") | ||
104 | self.assertRaises(ValueError, tmp_test) | ||
105 | |||
106 | def testruncommand(self): | ||
107 | self.assertEqual("Hello\n", self.m.run_command("echo Hello")) | ||
108 | def tmp_test(): | ||
109 | self.m.run_command("fff_garbage") | ||
110 | self.assertRaises(RuntimeError, tmp_test) | ||
111 | |||
112 | def testpathof(self): | ||
113 | self.assertEqual(self.m.src_path_of("a"), "src/a") | ||
114 | self.assertEqual(self.m.dst_path_of("a"), "dst/a") | ||
115 | self.m.prefix("tmp") | ||
116 | self.assertEqual(self.m.src_path_of("b/c"), "src/tmp/b/c") | ||
117 | self.assertEqual(self.m.dst_path_of("b/c"), "dst/tmp/b/c") | ||
118 | |||
119 | def testcmakedirs(self): | ||
120 | self.m.cmakedirs("test_dir_DELETE/nested/dir") | ||
121 | self.assert_(os.path.exists("test_dir_DELETE/nested/dir")) | ||
122 | self.assert_(os.path.isdir("test_dir_DELETE")) | ||
123 | self.assert_(os.path.isdir("test_dir_DELETE/nested")) | ||
124 | self.assert_(os.path.isdir("test_dir_DELETE/nested/dir")) | ||
125 | os.removedirs("test_dir_DELETE/nested/dir") | ||
126 | |||
127 | if __name__ == '__main__': | ||
128 | unittest.main() | ||
diff --git a/linden/indra/test/test_vc8.vcproj b/linden/indra/test/test_vc8.vcproj new file mode 100644 index 0000000..79af7f0 --- /dev/null +++ b/linden/indra/test/test_vc8.vcproj | |||
@@ -0,0 +1,385 @@ | |||
1 | <?xml version="1.0" encoding="Windows-1252"?> | ||
2 | <VisualStudioProject | ||
3 | ProjectType="Visual C++" | ||
4 | Version="8.00" | ||
5 | Name="test" | ||
6 | ProjectGUID="{BBAA6588-CA96-4A87-A988-B02270B8D02B}" | ||
7 | RootNamespace="test" | ||
8 | Keyword="Win32Proj" | ||
9 | > | ||
10 | <Platforms> | ||
11 | <Platform | ||
12 | Name="Win32" | ||
13 | /> | ||
14 | </Platforms> | ||
15 | <ToolFiles> | ||
16 | </ToolFiles> | ||
17 | <Configurations> | ||
18 | <Configuration | ||
19 | Name="Debug|Win32" | ||
20 | OutputDirectory="Debug" | ||
21 | IntermediateDirectory="Debug" | ||
22 | ConfigurationType="1" | ||
23 | InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops" | ||
24 | CharacterSet="2" | ||
25 | > | ||
26 | <Tool | ||
27 | Name="VCPreBuildEventTool" | ||
28 | /> | ||
29 | <Tool | ||
30 | Name="VCCustomBuildTool" | ||
31 | /> | ||
32 | <Tool | ||
33 | Name="VCXMLDataGeneratorTool" | ||
34 | /> | ||
35 | <Tool | ||
36 | Name="VCWebServiceProxyGeneratorTool" | ||
37 | /> | ||
38 | <Tool | ||
39 | Name="VCMIDLTool" | ||
40 | /> | ||
41 | <Tool | ||
42 | Name="VCCLCompilerTool" | ||
43 | Optimization="0" | ||
44 | AdditionalIncludeDirectories="..\llcommon;..\llmessage;..\llmath;..\..\libraries\include;..\llinventory;"..\..\libraries\i686-win32\include";..\llxml;..\lldatabase" | ||
45 | PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;LL_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;LL_DEBUG" | ||
46 | MinimalRebuild="false" | ||
47 | BasicRuntimeChecks="3" | ||
48 | RuntimeLibrary="1" | ||
49 | TreatWChar_tAsBuiltInType="false" | ||
50 | RuntimeTypeInfo="true" | ||
51 | UsePrecompiledHeader="0" | ||
52 | WarningLevel="3" | ||
53 | Detect64BitPortabilityProblems="false" | ||
54 | DebugInformationFormat="3" | ||
55 | /> | ||
56 | <Tool | ||
57 | Name="VCManagedResourceCompilerTool" | ||
58 | /> | ||
59 | <Tool | ||
60 | Name="VCResourceCompilerTool" | ||
61 | /> | ||
62 | <Tool | ||
63 | Name="VCPreLinkEventTool" | ||
64 | /> | ||
65 | <Tool | ||
66 | Name="VCLinkerTool" | ||
67 | AdditionalOptions="/FORCE:MULTIPLE" | ||
68 | AdditionalDependencies="advapi32.lib apr-1.lib aprutil-1.lib comdlg32.lib dinput8.lib dsound.lib dxerr8.lib dxguid.lib freetype.lib gdi32.lib glu32.lib jpeglib_6b.lib kernel32.lib libboost_regex-vc80-mt-s.lib libcurl.lib libeay32.lib libexpatMT.lib llcommon.lib llprimitive.lib llvfs.lib llxml.lib lscript_library.lib mswsock.lib netapi32.lib odbc32.lib odbccp32.lib ole32.lib oleaut32.lib opengl32.lib shell32.lib ssleay32.lib user32.lib Vfw32.lib winmm.lib winspool.lib ws2_32.lib xmlrpcepi.lib zlib.lib" | ||
69 | OutputFile="$(OutDir)/test.exe" | ||
70 | LinkIncremental="2" | ||
71 | AdditionalLibraryDirectories=""../lib_$(ConfigurationName)/i686-win32";"../../libraries/i686-win32/lib_debug"" | ||
72 | IgnoreDefaultLibraryNames="libcmt.lib" | ||
73 | GenerateDebugInformation="true" | ||
74 | ProgramDatabaseFile="$(OutDir)/test.pdb" | ||
75 | SubSystem="1" | ||
76 | TargetMachine="1" | ||
77 | /> | ||
78 | <Tool | ||
79 | Name="VCALinkTool" | ||
80 | /> | ||
81 | <Tool | ||
82 | Name="VCManifestTool" | ||
83 | /> | ||
84 | <Tool | ||
85 | Name="VCXDCMakeTool" | ||
86 | /> | ||
87 | <Tool | ||
88 | Name="VCBscMakeTool" | ||
89 | /> | ||
90 | <Tool | ||
91 | Name="VCFxCopTool" | ||
92 | /> | ||
93 | <Tool | ||
94 | Name="VCAppVerifierTool" | ||
95 | /> | ||
96 | <Tool | ||
97 | Name="VCWebDeploymentTool" | ||
98 | /> | ||
99 | <Tool | ||
100 | Name="VCPostBuildEventTool" | ||
101 | /> | ||
102 | </Configuration> | ||
103 | <Configuration | ||
104 | Name="Release|Win32" | ||
105 | OutputDirectory="Release" | ||
106 | IntermediateDirectory="Release" | ||
107 | ConfigurationType="1" | ||
108 | InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops" | ||
109 | CharacterSet="2" | ||
110 | > | ||
111 | <Tool | ||
112 | Name="VCPreBuildEventTool" | ||
113 | /> | ||
114 | <Tool | ||
115 | Name="VCCustomBuildTool" | ||
116 | /> | ||
117 | <Tool | ||
118 | Name="VCXMLDataGeneratorTool" | ||
119 | /> | ||
120 | <Tool | ||
121 | Name="VCWebServiceProxyGeneratorTool" | ||
122 | /> | ||
123 | <Tool | ||
124 | Name="VCMIDLTool" | ||
125 | /> | ||
126 | <Tool | ||
127 | Name="VCCLCompilerTool" | ||
128 | Optimization="0" | ||
129 | AdditionalIncludeDirectories="..\llcommon;..\llmessage;..\llmath;..\..\libraries\include;..\llinventory;"..\..\libraries\i686-win32\include";..\llxml;..\lldatabase" | ||
130 | PreprocessorDefinitions="WIN32;__WIN32;NDEBUG;_WINDOWS;LL_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;LL_RELEASE;APR_DECLARE_STATIC;LL_HTTPD=1" | ||
131 | MinimalRebuild="false" | ||
132 | BasicRuntimeChecks="3" | ||
133 | RuntimeLibrary="1" | ||
134 | TreatWChar_tAsBuiltInType="false" | ||
135 | ForceConformanceInForLoopScope="true" | ||
136 | RuntimeTypeInfo="true" | ||
137 | UsePrecompiledHeader="0" | ||
138 | WarningLevel="3" | ||
139 | Detect64BitPortabilityProblems="false" | ||
140 | DebugInformationFormat="3" | ||
141 | /> | ||
142 | <Tool | ||
143 | Name="VCManagedResourceCompilerTool" | ||
144 | /> | ||
145 | <Tool | ||
146 | Name="VCResourceCompilerTool" | ||
147 | /> | ||
148 | <Tool | ||
149 | Name="VCPreLinkEventTool" | ||
150 | /> | ||
151 | <Tool | ||
152 | Name="VCLinkerTool" | ||
153 | AdditionalOptions="/FORCE:MULTIPLE" | ||
154 | AdditionalDependencies="advapi32.lib apr-1.lib aprutil-1.lib comdlg32.lib dinput8.lib dsound.lib dxerr8.lib dxguid.lib freetype.lib gdi32.lib glu32.lib jpeglib_6b.lib kernel32.lib libboost_regex-vc80-mt-s.lib libcurl.lib libeay32.lib libexpatMT.lib llcommon.lib llprimitive.lib llvfs.lib llxml.lib lscript_library.lib mswsock.lib netapi32.lib odbc32.lib odbccp32.lib ole32.lib oleaut32.lib opengl32.lib shell32.lib ssleay32.lib user32.lib Vfw32.lib winmm.lib winspool.lib ws2_32.lib xmlrpcepi.lib zlib.lib" | ||
155 | OutputFile="$(OutDir)/test.exe" | ||
156 | LinkIncremental="2" | ||
157 | AdditionalLibraryDirectories=""../lib_$(ConfigurationName)/i686-win32";"../../libraries/i686-win32/lib_release"" | ||
158 | IgnoreDefaultLibraryNames="libcmt.lib" | ||
159 | GenerateDebugInformation="true" | ||
160 | ProgramDatabaseFile="$(OutDir)/test.pdb" | ||
161 | SubSystem="1" | ||
162 | TargetMachine="1" | ||
163 | /> | ||
164 | <Tool | ||
165 | Name="VCALinkTool" | ||
166 | /> | ||
167 | <Tool | ||
168 | Name="VCManifestTool" | ||
169 | /> | ||
170 | <Tool | ||
171 | Name="VCXDCMakeTool" | ||
172 | /> | ||
173 | <Tool | ||
174 | Name="VCBscMakeTool" | ||
175 | /> | ||
176 | <Tool | ||
177 | Name="VCFxCopTool" | ||
178 | /> | ||
179 | <Tool | ||
180 | Name="VCAppVerifierTool" | ||
181 | /> | ||
182 | <Tool | ||
183 | Name="VCWebDeploymentTool" | ||
184 | /> | ||
185 | <Tool | ||
186 | Name="VCPostBuildEventTool" | ||
187 | CommandLine="$(TargetPath)" | ||
188 | /> | ||
189 | </Configuration> | ||
190 | <Configuration | ||
191 | Name="ReleaseNoOpt|Win32" | ||
192 | OutputDirectory="$(ConfigurationName)" | ||
193 | IntermediateDirectory="$(ConfigurationName)" | ||
194 | ConfigurationType="1" | ||
195 | InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops" | ||
196 | CharacterSet="2" | ||
197 | > | ||
198 | <Tool | ||
199 | Name="VCPreBuildEventTool" | ||
200 | /> | ||
201 | <Tool | ||
202 | Name="VCCustomBuildTool" | ||
203 | /> | ||
204 | <Tool | ||
205 | Name="VCXMLDataGeneratorTool" | ||
206 | /> | ||
207 | <Tool | ||
208 | Name="VCWebServiceProxyGeneratorTool" | ||
209 | /> | ||
210 | <Tool | ||
211 | Name="VCMIDLTool" | ||
212 | /> | ||
213 | <Tool | ||
214 | Name="VCCLCompilerTool" | ||
215 | Optimization="0" | ||
216 | AdditionalIncludeDirectories="..\llcommon;..\llmessage;..\llmath;..\..\libraries\include;..\llinventory;"..\..\libraries\i686-win32\include";..\llxml;..\lldatabase" | ||
217 | PreprocessorDefinitions="WIN32;__WIN32;NDEBUG;_WINDOWS;LL_WINDOWS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;LL_RELEASE;APR_DECLARE_STATIC;LL_HTTPD=1" | ||
218 | MinimalRebuild="false" | ||
219 | BasicRuntimeChecks="3" | ||
220 | RuntimeLibrary="1" | ||
221 | TreatWChar_tAsBuiltInType="false" | ||
222 | ForceConformanceInForLoopScope="true" | ||
223 | RuntimeTypeInfo="true" | ||
224 | UsePrecompiledHeader="0" | ||
225 | WarningLevel="3" | ||
226 | Detect64BitPortabilityProblems="false" | ||
227 | DebugInformationFormat="3" | ||
228 | /> | ||
229 | <Tool | ||
230 | Name="VCManagedResourceCompilerTool" | ||
231 | /> | ||
232 | <Tool | ||
233 | Name="VCResourceCompilerTool" | ||
234 | /> | ||
235 | <Tool | ||
236 | Name="VCPreLinkEventTool" | ||
237 | /> | ||
238 | <Tool | ||
239 | Name="VCLinkerTool" | ||
240 | AdditionalDependencies="advapi32.lib apr-1.lib aprutil-1.lib comdlg32.lib dinput8.lib dsound.lib dxerr8.lib dxguid.lib freetype.lib gdi32.lib glu32.lib jpeglib_6b.lib kernel32.lib libboost_regex-vc80-mt-s.lib libcurl.lib libeay32.lib libexpatMT.lib llcommon.lib llprimitive.lib llvfs.lib llxml.lib lscript_library.lib mswsock.lib netapi32.lib odbc32.lib odbccp32.lib ole32.lib oleaut32.lib opengl32.lib shell32.lib ssleay32.lib user32.lib Vfw32.lib winmm.lib winspool.lib ws2_32.lib xmlrpcepi.lib zlib.lib" | ||
241 | OutputFile="$(OutDir)/test.exe" | ||
242 | LinkIncremental="2" | ||
243 | AdditionalLibraryDirectories=""../lib_$(ConfigurationName)/i686-win32";"../../libraries/i686-win32/lib_release"" | ||
244 | IgnoreDefaultLibraryNames="libcmt.lib" | ||
245 | GenerateDebugInformation="true" | ||
246 | ProgramDatabaseFile="$(OutDir)/test.pdb" | ||
247 | SubSystem="1" | ||
248 | TargetMachine="1" | ||
249 | /> | ||
250 | <Tool | ||
251 | Name="VCALinkTool" | ||
252 | /> | ||
253 | <Tool | ||
254 | Name="VCManifestTool" | ||
255 | /> | ||
256 | <Tool | ||
257 | Name="VCXDCMakeTool" | ||
258 | /> | ||
259 | <Tool | ||
260 | Name="VCBscMakeTool" | ||
261 | /> | ||
262 | <Tool | ||
263 | Name="VCFxCopTool" | ||
264 | /> | ||
265 | <Tool | ||
266 | Name="VCAppVerifierTool" | ||
267 | /> | ||
268 | <Tool | ||
269 | Name="VCWebDeploymentTool" | ||
270 | /> | ||
271 | <Tool | ||
272 | Name="VCPostBuildEventTool" | ||
273 | CommandLine="$(TargetPath)" | ||
274 | /> | ||
275 | </Configuration> | ||
276 | </Configurations> | ||
277 | <References> | ||
278 | </References> | ||
279 | <Files> | ||
280 | <Filter | ||
281 | Name="Source Files" | ||
282 | Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx" | ||
283 | UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}" | ||
284 | > | ||
285 | <File | ||
286 | RelativePath=".\common.cpp" | ||
287 | > | ||
288 | </File> | ||
289 | <File | ||
290 | RelativePath=".\inventory.cpp" | ||
291 | > | ||
292 | </File> | ||
293 | <File | ||
294 | RelativePath=".\io.cpp" | ||
295 | > | ||
296 | </File> | ||
297 | <File | ||
298 | RelativePath=".\lldatabase_tut.cpp" | ||
299 | > | ||
300 | </File> | ||
301 | <File | ||
302 | RelativePath=".\llerror_tut.cpp" | ||
303 | > | ||
304 | </File> | ||
305 | <File | ||
306 | RelativePath=".\llhttpclient_tut.cpp" | ||
307 | > | ||
308 | </File> | ||
309 | <File | ||
310 | RelativePath=".\llmime_tut.cpp" | ||
311 | > | ||
312 | </File> | ||
313 | <File | ||
314 | RelativePath=".\llpipeutil.cpp" | ||
315 | > | ||
316 | </File> | ||
317 | <File | ||
318 | RelativePath=".\llrandom_tut.cpp" | ||
319 | > | ||
320 | </File> | ||
321 | <File | ||
322 | RelativePath=".\llsd_message_system_tut.cpp" | ||
323 | > | ||
324 | </File> | ||
325 | <File | ||
326 | RelativePath=".\llsd_new_tut.cpp" | ||
327 | > | ||
328 | </File> | ||
329 | <File | ||
330 | RelativePath=".\llsdserialize_tut.cpp" | ||
331 | > | ||
332 | </File> | ||
333 | <File | ||
334 | RelativePath=".\lltiming_tut.cpp" | ||
335 | > | ||
336 | </File> | ||
337 | <File | ||
338 | RelativePath=".\lltut.cpp" | ||
339 | > | ||
340 | </File> | ||
341 | <File | ||
342 | RelativePath=".\lluri_tut.cpp" | ||
343 | > | ||
344 | </File> | ||
345 | <File | ||
346 | RelativePath=".\lluserrelations_tut.cpp" | ||
347 | > | ||
348 | </File> | ||
349 | <File | ||
350 | RelativePath=".\math.cpp" | ||
351 | > | ||
352 | </File> | ||
353 | <File | ||
354 | RelativePath=".\reflection_tut.cpp" | ||
355 | > | ||
356 | </File> | ||
357 | <File | ||
358 | RelativePath=".\test.cpp" | ||
359 | > | ||
360 | </File> | ||
361 | </Filter> | ||
362 | <Filter | ||
363 | Name="Header Files" | ||
364 | Filter="h;hpp;hxx;hm;inl;inc;xsd" | ||
365 | UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}" | ||
366 | > | ||
367 | <File | ||
368 | RelativePath=".\llpipeutil.h" | ||
369 | > | ||
370 | </File> | ||
371 | <File | ||
372 | RelativePath=".\lltut.h" | ||
373 | > | ||
374 | </File> | ||
375 | </Filter> | ||
376 | <Filter | ||
377 | Name="Resource Files" | ||
378 | Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx" | ||
379 | UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}" | ||
380 | > | ||
381 | </Filter> | ||
382 | </Files> | ||
383 | <Globals> | ||
384 | </Globals> | ||
385 | </VisualStudioProject> | ||