From 30eb751d1a778b73e20c238ec2f54b7293eb1b6f Mon Sep 17 00:00:00 2001 From: "gspencer@google.com" Date: Wed, 1 Jul 2009 22:30:03 +0000 Subject: Adding in most of the unit tests. This adds 406 of our unit tests into the gyp build. 21 of them fail, but that is only because they don't have test input yet -- I haven't added the build code that copies the test inputs into the build dir yet. Review URL: http://codereview.chromium.org/147129 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19778 0039d316-1c4b-4281-b951-d872f2087c98 --- o3d/tests/build.scons | 12 ++++++------ o3d/tests/common/win/testing_common.cc | 3 ++- 2 files changed, 8 insertions(+), 7 deletions(-) (limited to 'o3d/tests') diff --git a/o3d/tests/build.scons b/o3d/tests/build.scons index 83efd83..218fbda 100644 --- a/o3d/tests/build.scons +++ b/o3d/tests/build.scons @@ -153,12 +153,12 @@ if env.Bit('windows'): env.Help('\n') swiftshader_install = [] -if env.Bit('windows'): - # Copy SwiftShader to plugin dir. - swiftshader_path = env.subst('$SWIFTSHADER_DIR/swiftshader_d3d9.dll') - if os.path.exists(swiftshader_path): - swiftshader_install = env.Replicate('$ARTIFACTS_DIR/O3DExtras', - swiftshader_path) +if env.Bit('windows'): + # Copy SwiftShader to plugin dir. + swiftshader_path = env.subst('$SWIFTSHADER_DIR/swiftshader_d3d9.dll') + if os.path.exists(swiftshader_path): + swiftshader_install = env.Replicate('$ARTIFACTS_DIR/O3DExtras', + swiftshader_path) # ------------------------------------------------------------------------- # Unit tests diff --git a/o3d/tests/common/win/testing_common.cc b/o3d/tests/common/win/testing_common.cc index e51fc6a..702f970 100644 --- a/o3d/tests/common/win/testing_common.cc +++ b/o3d/tests/common/win/testing_common.cc @@ -160,7 +160,8 @@ int WINAPI WinMain(HINSTANCE instance, display_window = display_window; display_window->set_hwnd(g_window_handle); g_display_window = display_window; - bool offscreen = ::GetEnvironmentVariableW(kOffScreenRenderer, NULL, 0); + bool offscreen = (::GetEnvironmentVariableW(kOffScreenRenderer, + NULL, 0) == 0); if (offscreen) { success = g_renderer->Init(*g_display_window, true) == o3d::Renderer::SUCCESS; -- cgit v1.1