Changeset 86130 in webkit
- Timestamp:
- May 9, 2011 10:23:41 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/Configurations/JavaScriptCore.xcconfig
r84032 r86130 50 50 OTHER_CFLAGS_Release_normal = $(OTHER_CFLAGS_normal_$(TARGET_GCC_VERSION)); 51 51 OTHER_CFLAGS_Production_normal = $(OTHER_CFLAGS_normal_$(TARGET_GCC_VERSION)); 52 OTHER_CFLAGS_normal_GCC_42 = -f omit-frame-pointer -funwind-tables;52 OTHER_CFLAGS_normal_GCC_42 = -funwind-tables; 53 53 OTHER_CFLAGS_normal_LLVM_GCC_42 = $(OTHER_CFLAGS_normal_GCC_42); -
trunk/Source/ThirdParty/gtest/README.WebKit
r86108 r86130 2 2 3 3 http://googletest.googlecode.com/svn/tags/release-1.5.0/ 4 5 2011-05-06 Dmitry Lomov (dslomov@google.com)6 gtest-md.vcproj upgraded to VS 2005 (8.0) format to match the rest of WebKit -
trunk/Source/ThirdParty/gtest/msvc/gtest-md.vcproj
r86108 r86130 2 2 <VisualStudioProject 3 3 ProjectType="Visual C++" 4 Version=" 8.00"4 Version="7.10" 5 5 Name="gtest-md" 6 6 ProjectGUID="{C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}" 7 RootNamespace="gtest-md" 8 Keyword="Win32Proj" 9 > 7 Keyword="Win32Proj"> 10 8 <Platforms> 11 9 <Platform 12 Name="Win32" 13 /> 10 Name="Win32"/> 14 11 </Platforms> 15 <ToolFiles>16 </ToolFiles>17 12 <Configurations> 18 13 <Configuration 19 14 Name="Debug|Win32" 20 OutputDirectory="$(ConfigurationBuildDir)\lib" 15 OutputDirectory="$(SolutionName)/$(ConfigurationName)" 16 IntermediateDirectory="$(OutDir)/$(ProjectName)" 21 17 ConfigurationType="4" 22 InheritedPropertySheets="$(ProjectDir)\..\..\..\..\WebKitLibraries\win\tools\vsprops\common.vsprops"23 18 CharacterSet="2" 24 > 25 <Tool 26 Name="VCPreBuildEventTool" 27 /> 28 <Tool 29 Name="VCCustomBuildTool" 30 /> 31 <Tool 32 Name="VCXMLDataGeneratorTool" 33 /> 34 <Tool 35 Name="VCWebServiceProxyGeneratorTool" 36 /> 37 <Tool 38 Name="VCMIDLTool" 39 /> 19 ReferencesPath=""> 40 20 <Tool 41 21 Name="VCCLCompilerTool" 42 22 Optimization="0" 43 23 PreprocessorDefinitions="WIN32;_DEBUG;_LIB" 44 MinimalRebuild=" true"24 MinimalRebuild="TRUE" 45 25 BasicRuntimeChecks="3" 46 26 RuntimeLibrary="3" 47 27 UsePrecompiledHeader="0" 48 28 WarningLevel="3" 49 Detect64BitPortabilityProblems="false" 50 DebugInformationFormat="4" 51 /> 52 <Tool 53 Name="VCManagedResourceCompilerTool" 54 /> 55 <Tool 56 Name="VCResourceCompilerTool" 57 /> 58 <Tool 59 Name="VCPreLinkEventTool" 60 /> 29 Detect64BitPortabilityProblems="FALSE" 30 DebugInformationFormat="4"/> 31 <Tool 32 Name="VCCustomBuildTool"/> 61 33 <Tool 62 34 Name="VCLibrarianTool" 63 OutputFile="$(OutDir)\gtest.lib" 64 /> 65 <Tool 66 Name="VCALinkTool" 67 /> 68 <Tool 69 Name="VCXDCMakeTool" 70 /> 71 <Tool 72 Name="VCBscMakeTool" 73 /> 74 <Tool 75 Name="VCFxCopTool" 76 /> 77 <Tool 78 Name="VCPostBuildEventTool" 79 /> 35 OutputFile="$(OutDir)/gtestd.lib"/> 36 <Tool 37 Name="VCMIDLTool"/> 38 <Tool 39 Name="VCPostBuildEventTool"/> 40 <Tool 41 Name="VCPreBuildEventTool"/> 42 <Tool 43 Name="VCPreLinkEventTool"/> 44 <Tool 45 Name="VCResourceCompilerTool"/> 46 <Tool 47 Name="VCWebServiceProxyGeneratorTool"/> 48 <Tool 49 Name="VCXMLDataGeneratorTool"/> 50 <Tool 51 Name="VCManagedWrapperGeneratorTool"/> 52 <Tool 53 Name="VCAuxiliaryManagedWrapperGeneratorTool"/> 80 54 </Configuration> 81 55 <Configuration 82 56 Name="Release|Win32" 83 OutputDirectory="$(ConfigurationBuildDir)\lib" 57 OutputDirectory="$(SolutionName)/$(ConfigurationName)" 58 IntermediateDirectory="$(OutDir)/$(ProjectName)" 84 59 ConfigurationType="4" 85 InheritedPropertySheets="$(ProjectDir)\..\..\..\..\WebKitLibraries\win\tools\vsprops\common.vsprops"86 60 CharacterSet="2" 87 > 88 <Tool 89 Name="VCPreBuildEventTool" 90 /> 91 <Tool 92 Name="VCCustomBuildTool" 93 /> 94 <Tool 95 Name="VCXMLDataGeneratorTool" 96 /> 97 <Tool 98 Name="VCWebServiceProxyGeneratorTool" 99 /> 100 <Tool 101 Name="VCMIDLTool" 102 /> 61 ReferencesPath=""..\include";"..""> 103 62 <Tool 104 63 Name="VCCLCompilerTool" … … 107 66 UsePrecompiledHeader="0" 108 67 WarningLevel="3" 109 Detect64BitPortabilityProblems="false" 110 DebugInformationFormat="3" 111 /> 112 <Tool 113 Name="VCManagedResourceCompilerTool" 114 /> 115 <Tool 116 Name="VCResourceCompilerTool" 117 /> 118 <Tool 119 Name="VCPreLinkEventTool" 120 /> 68 Detect64BitPortabilityProblems="FALSE" 69 DebugInformationFormat="3"/> 70 <Tool 71 Name="VCCustomBuildTool"/> 121 72 <Tool 122 73 Name="VCLibrarianTool" 123 OutputFile="$(OutDir)\gtest.lib" 124 /> 125 <Tool 126 Name="VCALinkTool" 127 /> 128 <Tool 129 Name="VCXDCMakeTool" 130 /> 131 <Tool 132 Name="VCBscMakeTool" 133 /> 134 <Tool 135 Name="VCFxCopTool" 136 /> 137 <Tool 138 Name="VCPostBuildEventTool" 139 /> 74 OutputFile="$(OutDir)/gtest.lib"/> 75 <Tool 76 Name="VCMIDLTool"/> 77 <Tool 78 Name="VCPostBuildEventTool"/> 79 <Tool 80 Name="VCPreBuildEventTool"/> 81 <Tool 82 Name="VCPreLinkEventTool"/> 83 <Tool 84 Name="VCResourceCompilerTool"/> 85 <Tool 86 Name="VCWebServiceProxyGeneratorTool"/> 87 <Tool 88 Name="VCXMLDataGeneratorTool"/> 89 <Tool 90 Name="VCManagedWrapperGeneratorTool"/> 91 <Tool 92 Name="VCAuxiliaryManagedWrapperGeneratorTool"/> 140 93 </Configuration> 141 94 </Configurations> … … 146 99 Name="Source Files" 147 100 Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx" 148 UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}" 149 > 150 <File 151 RelativePath="..\src\gtest-death-test.cc" 152 > 153 <FileConfiguration 154 Name="Debug|Win32" 155 > 156 <Tool 157 Name="VCCLCompilerTool" 158 AdditionalIncludeDirectories=""..";"..\include"" 159 /> 160 </FileConfiguration> 161 <FileConfiguration 162 Name="Release|Win32" 163 > 164 <Tool 165 Name="VCCLCompilerTool" 166 AdditionalIncludeDirectories=""..";"..\include"" 167 /> 168 </FileConfiguration> 169 </File> 170 <File 171 RelativePath="..\src\gtest-filepath.cc" 172 > 173 <FileConfiguration 174 Name="Debug|Win32" 175 > 176 <Tool 177 Name="VCCLCompilerTool" 178 AdditionalIncludeDirectories=""..";"..\include"" 179 /> 180 </FileConfiguration> 181 <FileConfiguration 182 Name="Release|Win32" 183 > 184 <Tool 185 Name="VCCLCompilerTool" 186 AdditionalIncludeDirectories=""..";"..\include"" 187 /> 188 </FileConfiguration> 189 </File> 190 <File 191 RelativePath="..\src\gtest-port.cc" 192 > 193 <FileConfiguration 194 Name="Debug|Win32" 195 > 196 <Tool 197 Name="VCCLCompilerTool" 198 AdditionalIncludeDirectories=""..";"..\include"" 199 /> 200 </FileConfiguration> 201 <FileConfiguration 202 Name="Release|Win32" 203 > 204 <Tool 205 Name="VCCLCompilerTool" 206 AdditionalIncludeDirectories=""..";"..\include"" 207 /> 208 </FileConfiguration> 209 </File> 210 <File 211 RelativePath="..\src\gtest-test-part.cc" 212 > 213 <FileConfiguration 214 Name="Debug|Win32" 215 > 216 <Tool 217 Name="VCCLCompilerTool" 218 AdditionalIncludeDirectories=""..";"..\include"" 219 /> 220 </FileConfiguration> 221 <FileConfiguration 222 Name="Release|Win32" 223 > 224 <Tool 225 Name="VCCLCompilerTool" 226 AdditionalIncludeDirectories=""..";"..\include"" 227 /> 228 </FileConfiguration> 229 </File> 230 <File 231 RelativePath="..\src\gtest-typed-test.cc" 232 > 233 <FileConfiguration 234 Name="Debug|Win32" 235 > 236 <Tool 237 Name="VCCLCompilerTool" 238 AdditionalIncludeDirectories=""..";"..\include"" 239 /> 240 </FileConfiguration> 241 <FileConfiguration 242 Name="Release|Win32" 243 > 244 <Tool 245 Name="VCCLCompilerTool" 246 AdditionalIncludeDirectories=""..";"..\include"" 247 /> 248 </FileConfiguration> 249 </File> 250 <File 251 RelativePath="..\src\gtest.cc" 252 > 253 <FileConfiguration 254 Name="Debug|Win32" 255 > 256 <Tool 257 Name="VCCLCompilerTool" 258 AdditionalIncludeDirectories=""..";"..\include"" 259 /> 260 </FileConfiguration> 261 <FileConfiguration 262 Name="Release|Win32" 263 > 264 <Tool 265 Name="VCCLCompilerTool" 266 AdditionalIncludeDirectories=""..";"..\include"" 267 /> 101 UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"> 102 <File 103 RelativePath="..\src\gtest-death-test.cc"> 104 <FileConfiguration 105 Name="Debug|Win32"> 106 <Tool 107 Name="VCCLCompilerTool" 108 AdditionalIncludeDirectories=""..";"..\include""/> 109 </FileConfiguration> 110 <FileConfiguration 111 Name="Release|Win32"> 112 <Tool 113 Name="VCCLCompilerTool" 114 AdditionalIncludeDirectories=""..";"..\include""/> 115 </FileConfiguration> 116 </File> 117 <File 118 RelativePath="..\src\gtest-filepath.cc"> 119 <FileConfiguration 120 Name="Debug|Win32"> 121 <Tool 122 Name="VCCLCompilerTool" 123 AdditionalIncludeDirectories=""..";"..\include""/> 124 </FileConfiguration> 125 <FileConfiguration 126 Name="Release|Win32"> 127 <Tool 128 Name="VCCLCompilerTool" 129 AdditionalIncludeDirectories=""..";"..\include""/> 130 </FileConfiguration> 131 </File> 132 <File 133 RelativePath="..\src\gtest-port.cc"> 134 <FileConfiguration 135 Name="Debug|Win32"> 136 <Tool 137 Name="VCCLCompilerTool" 138 AdditionalIncludeDirectories=""..";"..\include""/> 139 </FileConfiguration> 140 <FileConfiguration 141 Name="Release|Win32"> 142 <Tool 143 Name="VCCLCompilerTool" 144 AdditionalIncludeDirectories=""..";"..\include""/> 145 </FileConfiguration> 146 </File> 147 <File 148 RelativePath="..\src\gtest-test-part.cc"> 149 <FileConfiguration 150 Name="Debug|Win32"> 151 <Tool 152 Name="VCCLCompilerTool" 153 AdditionalIncludeDirectories=""..";"..\include""/> 154 </FileConfiguration> 155 <FileConfiguration 156 Name="Release|Win32"> 157 <Tool 158 Name="VCCLCompilerTool" 159 AdditionalIncludeDirectories=""..";"..\include""/> 160 </FileConfiguration> 161 </File> 162 <File 163 RelativePath="..\src\gtest-typed-test.cc"> 164 <FileConfiguration 165 Name="Debug|Win32"> 166 <Tool 167 Name="VCCLCompilerTool" 168 AdditionalIncludeDirectories=""..";"..\include""/> 169 </FileConfiguration> 170 <FileConfiguration 171 Name="Release|Win32"> 172 <Tool 173 Name="VCCLCompilerTool" 174 AdditionalIncludeDirectories=""..";"..\include""/> 175 </FileConfiguration> 176 </File> 177 <File 178 RelativePath="..\src\gtest.cc"> 179 <FileConfiguration 180 Name="Debug|Win32"> 181 <Tool 182 Name="VCCLCompilerTool" 183 AdditionalIncludeDirectories=""..";"..\include""/> 184 </FileConfiguration> 185 <FileConfiguration 186 Name="Release|Win32"> 187 <Tool 188 Name="VCCLCompilerTool" 189 AdditionalIncludeDirectories=""..";"..\include""/> 268 190 </FileConfiguration> 269 191 </File> … … 272 194 Name="Header Files" 273 195 Filter="h;hpp;hxx;hm;inl;inc;xsd" 274 UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}" 275 > 276 <File 277 RelativePath="..\include\gtest\internal\gtest-death-test-internal.h" 278 > 279 </File> 280 <File 281 RelativePath="..\include\gtest\gtest-death-test.h" 282 > 283 </File> 284 <File 285 RelativePath="..\include\gtest\internal\gtest-filepath.h" 286 > 287 </File> 288 <File 289 RelativePath="..\src\gtest-internal-inl.h" 290 > 291 </File> 292 <File 293 RelativePath="..\include\gtest\internal\gtest-internal.h" 294 > 295 </File> 296 <File 297 RelativePath="..\include\gtest\gtest-message.h" 298 > 299 </File> 300 <File 301 RelativePath="..\include\gtest\internal\gtest-port.h" 302 > 303 </File> 304 <File 305 RelativePath="..\include\gtest\gtest-spi.h" 306 > 307 </File> 308 <File 309 RelativePath="..\include\gtest\internal\gtest-string.h" 310 > 311 </File> 312 <File 313 RelativePath="..\include\gtest\gtest.h" 314 > 315 </File> 316 <File 317 RelativePath="..\include\gtest\gtest_pred_impl.h" 318 > 319 </File> 320 <File 321 RelativePath="..\include\gtest\gtest_prod.h" 322 > 196 UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"> 197 <File 198 RelativePath="..\include\gtest\internal\gtest-death-test-internal.h"> 199 </File> 200 <File 201 RelativePath="..\include\gtest\gtest-death-test.h"> 202 </File> 203 <File 204 RelativePath="..\include\gtest\internal\gtest-filepath.h"> 205 </File> 206 <File 207 RelativePath="..\src\gtest-internal-inl.h"> 208 </File> 209 <File 210 RelativePath="..\include\gtest\internal\gtest-internal.h"> 211 </File> 212 <File 213 RelativePath="..\include\gtest\gtest-message.h"> 214 </File> 215 <File 216 RelativePath="..\include\gtest\internal\gtest-port.h"> 217 </File> 218 <File 219 RelativePath="..\include\gtest\gtest-spi.h"> 220 </File> 221 <File 222 RelativePath="..\include\gtest\internal\gtest-string.h"> 223 </File> 224 <File 225 RelativePath="..\include\gtest\gtest.h"> 226 </File> 227 <File 228 RelativePath="..\include\gtest\gtest_pred_impl.h"> 229 </File> 230 <File 231 RelativePath="..\include\gtest\gtest_prod.h"> 323 232 </File> 324 233 </Filter> -
trunk/Source/WebKit/win/ChangeLog
r86108 r86130 1 2011-05-09 Sheriff Bot <webkit.review.bot@gmail.com> 2 3 Unreviewed, rolling out r86108. 4 http://trac.webkit.org/changeset/86108 5 https://bugs.webkit.org/show_bug.cgi?id=60533 6 7 Broke makefile based builds and Cairo (Requested by weinig on 8 #webkit). 9 10 * WebKit.vcproj/WebKit.sln: 11 1 12 2011-05-09 Dmitry Lomov <dslomov@google.com> 2 13 -
trunk/Source/WebKit/win/WebKit.vcproj/WebKit.sln
r86108 r86130 153 153 {3E48AB23-D249-488F-A1C4-43CDF52FBD28} = {3E48AB23-D249-488F-A1C4-43CDF52FBD28} 154 154 EndProjectSection 155 EndProject156 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gtest-md", "..\..\..\ThirdParty\gtest\msvc\gtest-md.vcproj", "{C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}"157 155 EndProject 158 156 Global … … 512 510 {B0101604-B483-4F8C-9C51-90B46A2B1CD3}.Release|Win32.ActiveCfg = Release|Win32 513 511 {B0101604-B483-4F8C-9C51-90B46A2B1CD3}.Release|Win32.Build.0 = Release|Win32 514 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug_All|Win32.ActiveCfg = Debug|Win32515 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug_All|Win32.Build.0 = Debug|Win32516 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug_Cairo_CFLite|Win32.ActiveCfg = Debug|Win32517 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug_Cairo_CFLite|Win32.Build.0 = Debug|Win32518 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug|Win32.ActiveCfg = Debug|Win32519 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Debug|Win32.Build.0 = Debug|Win32520 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Production|Win32.ActiveCfg = Release|Win32521 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Production|Win32.Build.0 = Release|Win32522 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Release_Cairo_CFLite|Win32.ActiveCfg = Release|Win32523 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Release_Cairo_CFLite|Win32.Build.0 = Release|Win32524 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Release|Win32.ActiveCfg = Release|Win32525 {C8F6C172-56F2-4E76-B5FA-C3B423B31BE8}.Release|Win32.Build.0 = Release|Win32526 512 EndGlobalSection 527 513 GlobalSection(SolutionProperties) = preSolution -
trunk/Tools/ChangeLog
r86126 r86130 1 2011-05-09 Sheriff Bot <webkit.review.bot@gmail.com> 2 3 Unreviewed, rolling out r86108. 4 http://trac.webkit.org/changeset/86108 5 https://bugs.webkit.org/show_bug.cgi?id=60533 6 7 Broke makefile based builds and Cairo (Requested by weinig on 8 #webkit). 9 10 * Scripts/build-api-tests: 11 * Scripts/run-api-tests: 12 * TestWebKitAPI/Configurations/TestWebKitAPICommon.vsprops: 13 * TestWebKitAPI/Test.h: 14 (TestWebKitAPI::Test::~Test): 15 (TestWebKitAPI::Test::name): 16 (TestWebKitAPI::Test::Register::Register): 17 (TestWebKitAPI::Test::Register::create): 18 (TestWebKitAPI::Test::Test): 19 * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: 20 * TestWebKitAPI/Tests/WTF/VectorBasic.cpp: 21 (TestWebKitAPI::TEST): 22 * TestWebKitAPI/TestsController.cpp: 23 (TestWebKitAPI::TestsController::TestsController): 24 (TestWebKitAPI::TestsController::dumpTestNames): 25 (TestWebKitAPI::TestsController::runTestNamed): 26 (TestWebKitAPI::TestsController::testFailed): 27 (TestWebKitAPI::TestsController::registerCreateTestFunction): 28 * TestWebKitAPI/TestsController.h: 29 * TestWebKitAPI/mac/main.mm: 30 (main): 31 1 32 2011-05-09 Hayato Ito <hayato@chromium.org> 2 33 -
trunk/Tools/Scripts/build-api-tests
r86108 r86130 57 57 58 58 # Build 59 chdir "Tools/TestWebKitAPI" or die; 59 60 60 61 my $result; 61 62 if (isAppleMacWebKit()) { 62 chdir "Source/ThirdParty/gtest";63 buildXCodeProject("xcode/gtest", $clean, XcodeOptions(), @ARGV);64 chdir "../../../Tools/TestWebKitAPI" or die;65 63 $result = buildXCodeProject("TestWebKitAPI", $clean, XcodeOptions(), @ARGV); 66 64 } elsif (isAppleWinWebKit()) { 67 chdir "Tools/TestWebKitAPI" or die;68 65 $result = buildVisualStudioProject("win/TestWebKitAPI.sln", $clean); 69 66 } else { -
trunk/Tools/Scripts/run-api-tests
r86108 r86130 123 123 { 124 124 my ($suite, $testName) = @_; 125 my $test = $suite . " ." . $testName;125 my $test = $suite . "/" . $testName; 126 126 127 127 print " Test: $testName -> "; … … 236 236 for my $test (@tests) { 237 237 $test =~ s/[\r\n]*$//; 238 my ($suite, $testName) = split(/\ ./, $test);238 my ($suite, $testName) = split(/\//, $test); 239 239 push @{$keyedTests{$suite}}, $testName; 240 240 } -
trunk/Tools/TestWebKitAPI/Configurations/TestWebKitAPICommon.vsprops
r86108 r86130 7 7 <Tool 8 8 Name="VCCLCompilerTool" 9 AdditionalIncludeDirectories=""$(ProjectDir)";"$(ProjectDir)\..";"$(ConfigurationBuildDir)\include";"$(ConfigurationBuildDir)\include\WebCore\ForwardingHeaders";"$(ConfigurationBuildDir)\include\private";"$(WebKitLibrariesDir)\include";"$(ProjectDir)\..\..\..\Source\ThirdParty\gtest\include""9 AdditionalIncludeDirectories=""$(ProjectDir)";"$(ProjectDir)\..";"$(ConfigurationBuildDir)\include";"$(ConfigurationBuildDir)\include\WebCore\ForwardingHeaders";"$(ConfigurationBuildDir)\include\private";"$(WebKitLibrariesDir)\include"" 10 10 ForcedIncludeFiles="TestWebKitAPIPrefix.h" 11 11 /> 12 12 <Tool 13 13 Name="VCLinkerTool" 14 AdditionalDependencies="WebKit$(WebKitDLLConfigSuffix).lib JavaScriptCore$(WebKitDLLConfigSuffix).lib gtest.lib"14 AdditionalDependencies="WebKit$(WebKitDLLConfigSuffix).lib JavaScriptCore$(WebKitDLLConfigSuffix).lib" 15 15 SubSystem="1" 16 16 /> -
trunk/Tools/TestWebKitAPI/Test.h
r86108 r86130 29 29 #include "TestsController.h" 30 30 31 #include <gtest/gtest.h>32 33 31 namespace TestWebKitAPI { 34 32 35 #define TEST_ASSERT(expression) EXPECT_TRUE(expression) 36 #define TEST_ASSERT_RETURN(expression, returnValue) \ 37 do { \ 38 if (!(expression)) { \ 39 EXPECT_FALSE(true) << #expression; \ 40 return (returnValue); \ 33 // Abstract base class that all tests inherit from. 34 class Test { 35 public: 36 virtual ~Test() { } 37 38 virtual void run() = 0; 39 std::string name() const { return m_identifier; } 40 41 template<typename TestClassTy> class Register { 42 public: 43 Register(const std::string& testSuite, const std::string& testCase) 44 { 45 TestsController::shared().registerCreateTestFunction(testSuite + "/" + testCase, Register::create); 46 } 47 48 private: 49 static Test* create(const std::string& identifier) 50 { 51 return new TestClassTy(identifier); 52 } 53 }; 54 55 protected: 56 Test(const std::string& identifier) 57 : m_identifier(identifier) 58 { 59 } 60 61 std::string m_identifier; 62 }; 63 64 #define TEST_CLASS_NAME(testSuite, testCaseName) testSuite##testCaseName##_Test 65 #define TEST_REGISTRAR_NAME(testSuite, testCaseName) testSuite##testCaseName##_Registrar 66 67 // Use this to define a new test. 68 #define TEST(testSuite, testCaseName) \ 69 class TEST_CLASS_NAME(testSuite, testCaseName) : public Test { \ 70 public: \ 71 TEST_CLASS_NAME(testSuite, testCaseName)(const std::string& identifier) \ 72 : Test(identifier) \ 73 { \ 41 74 } \ 42 } while (0) 75 virtual void run(); \ 76 }; \ 77 \ 78 static Test::Register<TEST_CLASS_NAME(testSuite, testCaseName)> TEST_REGISTRAR_NAME(testSuite, testCaseName)(#testSuite, #testCaseName); \ 79 \ 80 void TEST_CLASS_NAME(testSuite, testCaseName)::run() 81 82 #define _TEST_ASSERT_HELPER(expression, returnStatement) do { if (!(expression)) { TestsController::shared().testFailed(__FILE__, __LINE__, #expression); returnStatement; } } while (0) 83 #define TEST_ASSERT(expression) _TEST_ASSERT_HELPER(expression, return) 84 #define TEST_ASSERT_RETURN(expression, returnValue) _TEST_ASSERT_HELPER(expression, return (returnValue)) 43 85 44 86 } // namespace TestWebKitAPI -
trunk/Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
r86108 r86130 58 58 C0BD669D131D3CF700E18F2A /* ResponsivenessTimerDoesntFireEarly.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C0BD669C131D3CF700E18F2A /* ResponsivenessTimerDoesntFireEarly.cpp */; }; 59 59 C0BD669F131D3CFF00E18F2A /* ResponsivenessTimerDoesntFireEarly_Bundle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C0BD669E131D3CFF00E18F2A /* ResponsivenessTimerDoesntFireEarly_Bundle.cpp */; }; 60 F3FC3EE313678B7300126A65 /* libgtest.a in Frameworks */ = {isa = PBXBuildFile; fileRef = F3FC3EE213678B7300126A65 /* libgtest.a */; };61 60 F6F3F29113342FEB00A6BF19 /* CookieManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F6F3F29013342FEB00A6BF19 /* CookieManager.cpp */; }; 62 61 /* End PBXBuildFile section */ … … 162 161 C0BD669C131D3CF700E18F2A /* ResponsivenessTimerDoesntFireEarly.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ResponsivenessTimerDoesntFireEarly.cpp; sourceTree = "<group>"; }; 163 162 C0BD669E131D3CFF00E18F2A /* ResponsivenessTimerDoesntFireEarly_Bundle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ResponsivenessTimerDoesntFireEarly_Bundle.cpp; sourceTree = "<group>"; }; 164 F3FC3EE213678B7300126A65 /* libgtest.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libgtest.a; path = ../../WebKitBuild/Debug/libgtest.a; sourceTree = SOURCE_ROOT; };165 163 F6F3F29013342FEB00A6BF19 /* CookieManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CookieManager.cpp; sourceTree = "<group>"; }; 166 164 /* End PBXFileReference section */ … … 175 173 BC90964E1255620C00083756 /* JavaScriptCore.framework in Frameworks */, 176 174 C02B7854126613AE0026BF0F /* Carbon.framework in Frameworks */, 177 F3FC3EE313678B7300126A65 /* libgtest.a in Frameworks */,178 175 ); 179 176 runOnlyForDeploymentPostprocessing = 0; … … 226 223 isa = PBXGroup; 227 224 children = ( 228 F3FC3EE213678B7300126A65 /* libgtest.a */,229 225 BCB9E9F011235BDE00A137E0 /* Cocoa.framework */, 230 226 BC90964D1255620C00083756 /* JavaScriptCore.framework */, … … 484 480 buildSettings = { 485 481 FRAMEWORK_SEARCH_PATHS = "$(inherited)"; 486 HEADER_SEARCH_PATHS = (487 ../../Source/ThirdParty/gtest/include,488 "$(WEBCORE_PRIVATE_HEADERS_DIR)/ForwardingHeaders",489 );490 LIBRARY_SEARCH_PATHS = (491 "$(inherited)",492 "\"$(SRCROOT)/../../WebKitBuild/Debug\"",493 );494 482 }; 495 483 name = Debug; … … 500 488 buildSettings = { 501 489 FRAMEWORK_SEARCH_PATHS = "$(inherited)"; 502 HEADER_SEARCH_PATHS = (503 ../../Source/ThirdParty/gtest/include,504 "$(WEBCORE_PRIVATE_HEADERS_DIR)/ForwardingHeaders",505 );506 LIBRARY_SEARCH_PATHS = (507 "$(inherited)",508 "\"$(SRCROOT)/../../WebKitBuild/Release\"",509 );510 490 }; 511 491 name = Release; -
trunk/Tools/TestWebKitAPI/Tests/WTF/VectorBasic.cpp
r86108 r86130 33 33 { 34 34 Vector<int> intVector; 35 ASSERT_TRUE(intVector.isEmpty());36 ASSERT_EQ(0ul, intVector.size());37 ASSERT_EQ(0ul, intVector.capacity());35 TEST_ASSERT(intVector.isEmpty()); 36 TEST_ASSERT(intVector.size() == 0); 37 TEST_ASSERT(intVector.capacity() == 0); 38 38 } 39 39 -
trunk/Tools/TestWebKitAPI/TestsController.cpp
r86108 r86130 27 27 28 28 #include "Test.h" 29 #include <algorithm> 29 30 #include <assert.h> 30 #include <gtest/gtest.h>31 #include <cstdio>32 31 33 32 namespace TestWebKitAPI { … … 40 39 41 40 TestsController::TestsController() 41 : m_testFailed(false) 42 , m_currentTest(0) 42 43 { 43 int argc = 0;44 ::testing::InitGoogleTest(&argc, (char**)0);45 44 } 46 45 47 46 void TestsController::dumpTestNames() 48 47 { 49 ::testing::UnitTest* unit_test = ::testing::UnitTest::GetInstance(); 50 51 for (int i = 0; i < unit_test->total_test_case_count(); i++) { 52 const ::testing::TestCase* test_case = unit_test->GetTestCase(i); 53 for (int j = 0; j < test_case->total_test_count(); j++) { 54 const ::testing::TestInfo* test_info = test_case->GetTestInfo(j); 55 printf("%s.%s\n", test_case->name(), test_info->name()); 56 } 57 } 48 std::map<std::string, CreateTestFunction>::const_iterator it = m_createTestFunctions.begin(); 49 std::map<std::string, CreateTestFunction>::const_iterator end = m_createTestFunctions.end(); 50 for (; it != end; ++it) 51 printf("%s\n", (*it).first.c_str()); 58 52 } 59 53 60 54 bool TestsController::runTestNamed(const std::string& identifier) 61 55 { 62 ::testing::GTEST_FLAG(filter) = identifier; 63 return !RUN_ALL_TESTS(); 56 CreateTestFunction createTestFunction = m_createTestFunctions[identifier]; 57 if (!createTestFunction) { 58 printf("ERROR: Test not found - %s\n", identifier.c_str()); 59 return false; 60 } 61 62 m_currentTest = createTestFunction(identifier); 63 m_currentTest->run(); 64 65 delete m_currentTest; 66 m_currentTest = 0; 67 68 return !m_testFailed; 64 69 } 65 70 66 bool TestsController::runAllTests()71 void TestsController::testFailed(const char* file, int line, const char* message) 67 72 { 68 return !RUN_ALL_TESTS(); 73 m_testFailed = true; 74 printf("FAIL: %s\n\t%s (%s:%d)\n", m_currentTest->name().c_str(), message, file, line); 75 } 76 77 void TestsController::registerCreateTestFunction(const std::string& identifier, CreateTestFunction createTestFunction) 78 { 79 m_createTestFunctions[identifier] = createTestFunction; 69 80 } 70 81 -
trunk/Tools/TestWebKitAPI/TestsController.h
r86108 r86130 40 40 void dumpTestNames(); 41 41 bool runTestNamed(const std::string&); 42 bool runAllTests(); 42 43 // Called by the tests themselves. 44 void testFailed(const char* file, int line, const char* message); 45 46 typedef Test* (*CreateTestFunction)(const std::string&); 47 void registerCreateTestFunction(const std::string&, CreateTestFunction); 43 48 44 49 private: 45 50 TestsController(); 46 51 ~TestsController(); 52 53 bool m_testFailed; 54 Test* m_currentTest; 55 56 std::map<std::string, CreateTestFunction> m_createTestFunctions; 47 57 }; 48 58 -
trunk/Tools/TestWebKitAPI/mac/main.mm
r86108 r86130 34 34 bool passed = true; 35 35 36 if (argc == 1) 37 passed = TestWebKitAPI::TestsController::shared().runAllTests(); 38 else { 39 std::string argument(argv[1]); 40 if (argument == "--dump-tests") 41 TestWebKitAPI::TestsController::shared().dumpTestNames(); 42 else 43 passed = TestWebKitAPI::TestsController::shared().runTestNamed(argument); 44 } 36 std::string argument(argv[1]); 37 if (argument == "--dump-tests") 38 TestWebKitAPI::TestsController::shared().dumpTestNames(); 39 else 40 passed = TestWebKitAPI::TestsController::shared().runTestNamed(argument); 45 41 46 42 [pool drain];
Note: See TracChangeset
for help on using the changeset viewer.