Log of /branches/WIP-pyshapelib-bramz/test/support.py
Parent Directory
|
Revision Log
Revision
2642 -
(
view)
(
annotate)
-
[selected]
Modified
Fri Jul 1 20:49:04 2005 UTC
(19 years, 8 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 12280 byte(s)
Diff to
previous 2624
First step towards unicode. With this roughly we're at step 1
string_representation.txt
* Doc/technotes/string_representation.txt: New. Document how
strings are represented in Thuban and how to get to a Unicode
Thuban.
* Thuban/__init__.py (set_internal_encoding)
(unicode_from_internal, internal_from_unicode): New. The first few
functions for the internal string representation
* Thuban/UI/about.py (unicodeToLocale): Removed. Use
internal_from_unicode instead.
* Thuban/UI/__init__.py (install_wx_translation): Determine the
encoding to use for the internal string representation. Also,
change the translation function to return strings in internal
representation even on unicode builds of wxPython
* Thuban/Model/load.py (SessionLoader.check_attrs): Decode
filenames too.
(SessionLoader.start_clrange): Use check_attrs to decode and check
the attributes.
* Thuban/Model/xmlreader.py (XMLReader.encode): Use
internal_from_unicode to convert unicode strings.
* Thuban/Model/xmlwriter.py (XMLWriter.encode): Use
unicode_from_internal when applicable
* test/runtests.py (main): New command line option:
internal-encoding to specify the internal string encoding to use
in the tests.
* test/support.py (initthuban): Set the internal encoding to
latin-1
* test/test_load.py (TestSingleLayer.test, TestClassification.test)
(TestLabelLayer.test): Use the internal string representation when
dealing with non-ascii characters
* test/test_load_1_0.py (TestSingleLayer.test)
(TestClassification.test, TestLabelLayer.test): Use the internal
string representation when dealing with non-ascii characters
* test/test_load_0_9.py (TestSingleLayer.test)
(TestClassification.test): Use the internal string representation
when dealing with non-ascii characters
* test/test_load_0_8.py (TestUnicodeStrings.test): Use the
internal string representation when dealing with non-ascii
characters
* test/test_save.py (XMLWriterTest.testEncode)
(SaveSessionTest.testClassifiedLayer): Use the internal string
representation when dealing with non-ascii characters where
applicable
Revision
1673 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Thu Aug 28 13:04:44 2003 UTC
(21 years, 6 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 11318 byte(s)
Diff to
previous 1605
,
to
selected 2642
(print_garbage_information): Call initthuban
here because it may be called indirectly from test cases that test
test support modules which do not use anything from thuban itself
(ThubanTestProgram.runTests): Remove unnecessary debug print
Revision
1605 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Tue Aug 19 11:00:40 2003 UTC
(21 years, 6 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 11129 byte(s)
Diff to
previous 1601
,
to
selected 2642
Add very basic postgis database support and the corresponding test
cases. The test cases require a PostgreSQL + postgis installation
but no existing database. The database will be created
automatically by the test cases
* test/README: Add note about skipped tests and the requirements
of the postgis tests.
* Thuban/Model/postgisdb.py: New. Basic postgis database support.
* test/test_postgis_db.py: New. Test cases for the postgis
support.
* Thuban/Model/wellknowntext.py: New. Parser for well-known-text
format
* test/test_wellknowntext.py: New. Test cases for the
wellknowntext parser
* test/postgissupport.py: New. Support module for tests involving
a postgis database.
* test/support.py (execute_as_testsuite): Shut down the postmaster
if it's still running after the tests
* Thuban/Model/data.py (RAW_WKT): New constant for raw data in
well known text format
Revision
1601 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Mon Aug 18 17:22:07 2003 UTC
(21 years, 6 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 10937 byte(s)
Diff to
previous 1574
,
to
selected 2642
* test/support.py (ThubanTestResult.printErrors): Indent the
reason for the skips in the output to make it a bit more readable.
(execute_as_testsuite): New helper function to run a test suite
and print some more information.
(run_tests): Use execute_as_testsuite to run the tests
* test/runtests.py (main): Use execute_as_testsuite to run the
tests
Revision
1555 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Thu Aug 7 15:41:05 2003 UTC
(21 years, 7 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 9819 byte(s)
Diff to
previous 1421
,
to
selected 2642
* test/support.py (SkipTest, ThubanTestResult, ThubanTestRunner)
(ThubanTestProgram): New classes that extend the respective
classes from unittest. These new version support skipping tests
under certain expected conditions. In the Thuban test suite we
uses this for tests that require the optional gdal support.
(run_tests): Use ThubanTestProgram instead of the unittest.main()
* test/runtests.py (main): Use the new ThubanTestRunner instead of
the normal one from unittest
* test/test_layer.py (TestLayer.test_raster_layer): If this test
is not run because gdal support isn't available report this to the
runner.
* test/test_baserenderer.py
(TestBaseRenderer.test_raster_no_projection): Do not run this test
if gdal support isn't available and report this to the runner.
Revision
1421 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Tue Jul 15 14:46:55 2003 UTC
(21 years, 7 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 7302 byte(s)
Diff to
previous 1397
,
to
selected 2642
* test/support.py (FloatComparisonMixin): This is a mix-in class
and therefore should not be derived from any other class.
* test/test_range.py (RangeTest): FloatComparisonMixin is a
mix-in, so derive from TestCase as well.
Revision
1245 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Thu Jun 19 19:29:23 2003 UTC
(21 years, 8 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 8015 byte(s)
Diff to
previous 956
,
to
selected 2642
Add XML validation to some of the tests. Validation will only be
done if pyRXP is installed (http://reportlab.com/xml/pyrxp.html).
To make the DTD available to the test cases it's moved into
Resources/XML
* Resources/XML/thuban.dtd: New. This is now the real Thuban DTD
for versions up to and including 0.2. Two slight changes: added an
encoding specification and fixed the comment which refered to
GRASS, not Thuban
* test/xmlsupport.py: New support module for tests involving XML.
Currently there's a mix-in class for XML validation.
* test/test_xmlsupport.py: New. Tests for the xmlsupport module
* test/test_save.py (SaveSessionTest): Derive from ValidationTest
so that we can validate the
(SaveSessionTest.testEmptySession)
(SaveSessionTest.testSingleLayer)
(SaveSessionTest.testSingleLayer)
(SaveSessionTest.testLayerProjection)
(SaveSessionTest.testRasterLayer)
(SaveSessionTest.testClassifiedLayer): Validate the generated XML
* test/runtests.py (main): Call print_additional_summary instead
of print_garbage_information
* test/support.py (resource_dir): New function to return the
"Resource" subdirectory
(print_additional_summary): New function to combine several
summary functions
(run_tests): Use print_additional_summary instead of calling
print_garbage_information directly
Revision
596 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Thu Apr 3 11:37:01 2003 UTC
(21 years, 11 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 5546 byte(s)
Diff to
previous 342
,
to
selected 2642
(print_garbage_information): New function that
prints information about still connected messages and memory
leaks.
(run_suite): Removed.
(run_tests): New function for use as a replacement of
unittest.main in the test_* files. This one calls
print_garbage_information at the end.
Revision
342 -
(
view)
(
annotate)
-
[select for diffs]
Modified
Fri Oct 18 17:28:46 2002 UTC
(22 years, 4 months ago)
by
bh
Original Path:
trunk/thuban/test/support.py
File length: 4745 byte(s)
Diff to
previous 324
,
to
selected 2642
(FloatComparisonMixin.assertFloatEqual)
(FloatComparisonMixin.assertFloatSeqEqual): give a more useful
message if the assertion fails and don't return the return value
of self.assert_. In assertFloatSeqEqual the return meant that not
all items of the sequence were compared.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.