gecko-dev/intl/lwbrk/moz.build
Nicholas Nethercote 108b8f0823 Bug 1314497 (part 1) - Convert intl/lwbrk/tests/TestLineBreak.cpp to a gtest. r=emk.
This commit does the following.

- Converts the test to a gtest, including renaming the directory.

- Factors out the duplicated checking code into a separate Check() function.

- Avoids printing any output unless a failure occurs. (The gtest harness prints
  out minimal output, like the name of the current test.)

- Removes SampleWordBreakUsage(), which prints some output but doesn't actually
  test anything, and so isn't useful.

--HG--
rename : intl/lwbrk/tests/TestLineBreak.cpp => intl/lwbrk/gtest/TestLineBreak.cpp
rename : intl/lwbrk/tests/moz.build => intl/lwbrk/gtest/moz.build
extra : rebase_source : e673299e237a1a8a3b0a33cfc0a0024ab7dee271
2016-11-03 13:46:12 +11:00

49 lines
1.0 KiB
Python

# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
TEST_DIRS += ['gtest']
XPIDL_SOURCES += [
'nsISemanticUnitScanner.idl',
]
XPIDL_MODULE = 'lwbrk'
EXPORTS += [
'nsILineBreaker.h',
'nsIWordBreaker.h',
'nsLWBrkCIID.h',
]
UNIFIED_SOURCES += [
'nsJISx4051LineBreaker.cpp',
'nsSampleWordBreaker.cpp',
'nsSemanticUnitScanner.cpp',
]
if 'gtk' in CONFIG['MOZ_WIDGET_TOOLKIT']:
SOURCES += [
'nsPangoBreaker.cpp',
]
CXXFLAGS += CONFIG['MOZ_PANGO_CFLAGS']
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
SOURCES += [
'nsUniscribeBreaker.cpp',
]
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
UNIFIED_SOURCES += [
'nsCarbonBreaker.cpp',
]
else:
SOURCES += [
'nsRuleBreaker.cpp',
]
SOURCES += [
'rulebrk.c',
]
FINAL_LIBRARY = 'xul'