summaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* Some more loplugin:cstylecast: testStephan Bergmann2015-01-201-2/+2
| | | | Change-Id: I48397ba0cc3c0737f6c47808d353245f81050a2b
* fdo#84938: convert STREAM_ #defines to 'enum class'Noel Grandin2015-01-074-4/+4
| | | | Change-Id: Ibbf14c7e9a5c1883c1311d4c86f948f74f8e473e
* Let MetafileXmlDump::dumpAndParse() take a const GDIMetaFileMiklos Vajna2014-12-191-3/+4
| | | | | | So the const_cast<> in CppunitTest_sw_uiwriter can go away. Change-Id: Id7d4234154cd6bed43cb5270b50208061038dcf7
* test: Use appropriate OUString functions on string constantsStephan Bergmann2014-12-181-1/+1
| | | | Change-Id: Idbdc5c9aab8fa65df39d66da2461337db6350e52
* test: Use appropriate OUString functions on string constantsStephan Bergmann2014-12-181-2/+2
| | | | Change-Id: Id4327a479fd61b3793a2b8b250203edcfe3e6754
* XmlTestTools: fix conversion from UTF-8 xmlChar strings to OUStringStephan Bergmann2014-12-181-3/+20
| | | | | | | ...which resolves the mystery of 0ba6360363fb73b5b200bbc486ed8eeac5f3d337 "Garbage in, garbage out?" Change-Id: I51f102699d0474872c80392b27f71030b5e3fb59
* CppunitTest --headless is not the same as soffice --headlessStephan Bergmann2014-12-103-2/+42
| | | | | | ...they just "happen" to have the same name Change-Id: Ia602f9a62e07c3af6fba2ffb84a858e1fb4b09ce
* Unittest for autocorrect in writerDaniel Sikeler2014-11-282-0/+1
| | | | | | | | | | | | | | | | | | At first we test normal replacement of wrong words. Second part of the test is about style changes during autocorrection. And at the end we replace a word with a table. The rules for the autocorrection are in test/user-template/user/autocorr/acor_fr.dat I needed to make SwAutoCorrect public for my test. Conflicts: sw/qa/extras/uiwriter/uiwriter.cxx Change-Id: Ie753c2187c1f4eddaefe0cc428a605107112c24f Reviewed-on: https://gerrit.libreoffice.org/13131 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
* Fix common typos. No automatic tools. Handmade…Andrea Gelmini2014-11-121-1/+1
| | | | | | | Change-Id: I1ab4e23b0539f8d39974787f226e57a21f96e959 Reviewed-on: https://gerrit.libreoffice.org/12164 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
* perfcheck instrument existing test : replaceAllLaurent Godard2014-11-121-0/+4
| | | | | | | Change-Id: I7766aa6d69810124b27763912c3e7a8399637280 Reviewed-on: https://gerrit.libreoffice.org/12243 Reviewed-by: Matúš Kukan <matus.kukan@collabora.com> Tested-by: Matúš Kukan <matus.kukan@collabora.com>
* Revert "use the new OUString::fromUtf8 method"Stephan Bergmann2014-11-061-1/+1
| | | | | | | | This reverts commit 05050cdb23de586870bf479a9df5ced06828d498, not all places that use e.g. OStringToOUString to convert potential UTF-8 are guaranteed to fulfil the prerequisites necessary to use fromUtf8 (and some places like e.g. in codemaker are happy with the best-effort effect of OStringToOUString's OSTRING_TO_OUSTRING_CVTFLAGS).
* use the new OUString::fromUtf8 methodNoel Grandin2014-11-061-1/+1
| | | | Change-Id: I771004b7ccab3344a67e827e45bc34c22ffa5f77
* Improve framework for callgrind performance unit testsMatúš Kukan2014-10-292-0/+35
| | | | | | | | | | | | | | | Do not abort in tests which take longer then before. Since 4f5f6d2444a24138c3d3d378771f87cb06427195 we have nice tool to collect callgrind results, store them.. Also, make it not necessary to duplicate anything. Any test can be turned into a performance test by using callgrindStart/callgrindDump. You only need to duplicate the makefile name in gb_Module_add_perfcheck_targets. So, if the test is run as part of 'perfcheck', it runs under callgrind, otherwise it behaves like a regular unit test. Change-Id: I7acbb855b1823c9a32ba126abb57dccc767ca239
* sc: fix temp file leak in ScTableSheetsObjMichael Stahl2014-10-211-1/+7
| | | | Change-Id: Iff838c97c1cf633f99e75a169eeb8bb324d4a32a
* create a macro library for implementing bit-flags typesNoel Grandin2014-10-131-15/+15
| | | | | | | | | | | Signed-off-by: Stephan Bergmann <sbergman@redhat.com>, changed from a macro- to a template-based solution. (Unfortunately MSVC 2012 does not support explicit conversion operators. Worked around that with explicit #ifs rather than some HAVE_EXPLICIT_CONVERSION_OPERATORS and SAL_EXPLICIT_CONVERSION_OPERATOR ainticipating we hopefully soon move to a baseline that requires unconditional support for them.) Change-Id: I4a89643b218d247e8e4a861faba458ec6dfe1396
* sc: ensure global variables in tests are cleared before shutdownMichael Stahl2014-09-301-50/+45
| | | | | | | If the destructors run from exit handlers, they could access already deleted globals from VCL etc. and crash. Change-Id: I265046e95998a4384e1ce0f1f205d03c078a40a9
* Factor out duplicated code to XmlTestTools::assertXPathNoAttribute()Miklos Vajna2014-09-301-0/+12
| | | | Change-Id: I1eb3778e6bcdd8c44ffb9a7548add109331fc83b
* Include name of document in CPPUNIT_ASSERT msgsStephan Bergmann2014-09-232-9/+16
| | | | Change-Id: Ia0d06d1e0951bcc3930d5e059658209a2916405f
* fdo#82577: Handle FontNoel Grandin2014-09-181-1/+1
| | | | | | | Put the VCL Font class in the vcl namespace. Avoids clash with the X11 Font typedef. Change-Id: I1a84f7cad8b31697b9860a3418f7dff794ff6537
* coverity#1233488 Unchecked dynamic_castCaolán McNamara2014-09-021-1/+2
| | | | Change-Id: I9599fb4473a43a4624d64c48e8768761fcbd266f
* parseXml should return xmlDocPtr instead of htmlDocPtrTomaž Vajngerl2014-08-281-1/+1
| | | | Change-Id: Ia9fb79ea40ca840d7328a078e747ad64a63d18f1
* vcl: convert push flags to type-safe enum-like classNoel Grandin2014-08-211-4/+4
| | | | Change-Id: Ib49a0dd5ecee0225f51bea2ff1c0ab5326595a47
* Fix another: reference to 'Primitive2DSequence' is ambiguousMatteo Casalin2014-08-171-1/+1
| | | | Change-Id: I8b78126cab64f023ffcb35c080576148b1eb15f5
* Fix: reference to 'Primitive2DSequence' is ambiguousMatteo Casalin2014-08-171-2/+6
| | | | Change-Id: Ic6cf4bc6dab4b9e2610aebdc42e3df7b56eda59d
* loplugin:passstuffbyref (Primitive2DSequence)Matteo Casalin2014-08-171-2/+2
| | | | Change-Id: I3d9c6daa09d71ca872021fe13405b08050e191d9
* initial implementation of XML dump for Primitive2DSequenceTomaž Vajngerl2014-08-162-0/+186
| | | | Change-Id: I6618b18164a26553f81a1c737e009b7187b028c3
* XmlWriter: simplify and take SvStream* as inputTomaž Vajngerl2014-08-162-21/+29
| | | | Change-Id: I56b2fa6887f7971604a2dcf34497ecda9cea8937
* mtfxmldump: move XML writing into its own functionTomaž Vajngerl2014-08-161-104/+108
| | | | Change-Id: I82954177fe9d4934e69b33c1c985304add09e089
* No need to write 'Tomaž Vajngerl2014-08-161-4/+3
| | | | Change-Id: I0562defc6fc60ee83bc73b901caf46b1283a9df9
* XStyleLoader2 : enhance unit test to PageStyleLaurent Godard2014-08-111-19/+17
| | | | | | | | | and remove duplicate code Change-Id: Ib9e3568c860fe5cd3f11374a1c61dff101e33a18 Reviewed-on: https://gerrit.libreoffice.org/10832 Reviewed-by: David Tardon <dtardon@redhat.com> Tested-by: David Tardon <dtardon@redhat.com>
* fix ambiguity in argumentMarkus Mohrhard2014-08-081-3/+3
| | | | Change-Id: I00146441b1271d7a3c866ad58d1b3c72b845dc0c
* XStyleLoader2 loadStylesFromDocument - unit testsLaurent Godard2014-08-082-0/+101
| | | | Change-Id: Id143689f573e6f8585db9bc48a252e311ff0e721
* Improve test failure outputStephan Bergmann2014-08-061-4/+6
| | | | Change-Id: I4417318988ef70639cbcec9d776c783ad69c3990
* Remove some unused codeMarcos Paulo de Souza2014-07-291-5/+0
| | | | | | | Change-Id: Ib1fb5108a858c35a5bbe8ba865e15660639725e3 Reviewed-on: https://gerrit.libreoffice.org/10593 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
* xmlwriter: set indent and always write utf8 xml documentTomaž Vajngerl2014-07-201-1/+2
| | | | Change-Id: I1477833e696edbac2dc375329e7b26a7105d1593
* Support color related MTF actions in mtfxmldumpTomaž Vajngerl2014-07-201-7/+54
| | | | Change-Id: I5deac7f096866a8f149acfd0d11bbc0963238e88
* Extend metafile to xml dump testing tool with more MFT actionsTomaž Vajngerl2014-07-202-31/+117
| | | | Change-Id: I819de476c6a615b8cf27a6a26d41a6e9ac25ef85
* improve test failure messageMarkus Mohrhard2014-07-041-2/+2
| | | | Change-Id: I71d6b65b046bfc31692ba12423288c55fccb2d02
* correct XSheetAnnotations GetByIndex test for #fdo#80551Laurent Godard2014-07-021-14/+14
| | | | | | | | | | the previous testGetCount test already added a note on sheet 2 testGetByIndex now works on sheet 3 Change-Id: I2cd49aa2bbf5c1b707287518e0f15088f3ee5ec0 Reviewed-on: https://gerrit.libreoffice.org/9938 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
* unit test XSheetAnnotations GetByIndex for #fdo80551Laurent Godard2014-07-021-0/+49
| | | | | | | Change-Id: I89ebc3d5ac257f3c754a050caf3776959b81d8b3 Reviewed-on: https://gerrit.libreoffice.org/9933 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
* xmlChildElementCount is only available in libxml2 >= 2.7.3Douglas Mencken2014-06-161-0/+6
| | | | | | | | | fixes build error Undefined symbols: _xmlChildElementCount Change-Id: I9687971912b4d0ae55bf1d9ad987fd339fcbec7e Reviewed-on: https://gerrit.libreoffice.org/9788 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
* Fix vclplug_* dependencies for gb_CppunitTest_use_vclStephan Bergmann2014-06-122-14/+0
| | | | | | | ...and replace gb_CppunitTest_unset_headless with gb_CppunitTest_use_vcl_non_headless. Change-Id: Ibd859f98ed8df09988ca26ffcee26e06e25d8313
* MetafileXmlDump: Add dumping of META_CLIPREGION_ACTION's.Jan Holesovsky2014-06-101-1/+20
| | | | Change-Id: I4b51abf6193c33367edebc82772054875b5b9bba
* MetafileXmlDump: No need to specify the stream, simplify the API.Jan Holesovsky2014-06-101-5/+20
| | | | Change-Id: Ia08f67e359bbd26cefdba8661f0b0c4ae2147382
* Missing new files from previous commitStephan Bergmann2014-06-042-0/+127
| | | | Change-Id: Ic8d7c13602c8831e411181c802eb825124578b19
* DeInitVCL at end of testsStephan Bergmann2014-06-042-15/+17
| | | | | | | | | | | | | | | | | | | | | This required some changes to the framework: * Init-/DeInitVCL is no longer done per individual test in BootstrapFixture, but once per CppunitTest invocation in a new vclbootstrapprotector (similarly to the exisiting unobootstrapprotector). CppunitTests that need VCL now need to declare gb_CppunitTest_use_vcl. * For things to work properly, the UNO component context needs to be disposed from within DeInitVCL (cf. Desktop's Application::DeInit called from DeInitVCL). The easiest solution was to introduce an Application::setDeInitHook (where the hook is called from DeInitVCL) specifically for vclbootstrapprotector to call. * PythonTests don't (yet) call DeInitVCL; they still hook into BootstrapFixture's original test_init functionality (to call InitVCL), and do not make use of the vclbootstrapprotector. Change-Id: I4f3a3c75db30b58c1cd49d81c51db14902ed68b2
* Fix memory leaks in test codeStephan Bergmann2014-06-021-9/+24
| | | | Change-Id: Ifa756a5da636e0b37654ad83900115872bc40f0e
* Remove unnecessary semicolonsPeter Senna Tschudin2014-05-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | A simplified version of the semantic match that finds this problem is follows: (http://coccinelle.lip6.fr/) // <smpl> @r1@ statement S; position p,p1; @@ S@p1;@p @script:python r2@ p << r1.p; p1 << r1.p1; @@ if p[0].line != p1[0].line_end: cocci.include_match(False) @@ position r1.p; @@ -;@p // </smpl> Change-Id: Ib9708d37fbb4c6060f88d5dae3814a2d37b2091e Reviewed-on: https://gerrit.libreoffice.org/9493 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
* cppcheck: unreadVariableThomas Arnhold2014-05-241-4/+0
| | | | Change-Id: Ifbcae35c0cf3bdb9ba5c680b1627117c47d6c9a0
* Avoid including <config_features.h> in <vcl/svapp.hxx>Tor Lillqvist2014-05-221-0/+3
| | | | Change-Id: I711621c89e8f75d4450867e303ccdc8017bcd9d7