Commit Graph

25 Commits

Author SHA1 Message Date
Stefan Weil
6b8b1f0007 unittest: Remove some dependencies on abseil
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-08-06 20:59:09 +02:00
Stefan Weil
4530763329 Fix some compiler warnings
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:15:09 +01:00
Stefan Weil
fbaac9dc9d Modernize code (clang-tidy -checks='-*,google-readability-braces-around-statements')
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:03:51 +01:00
Stefan Weil
77ed2886a7 Modernize code (clang-tidy -checks='-*,modernize-loop-convert')
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:51 +01:00
Stefan Weil
cb80eb6963 Modernize code (clang-tidy -checks='-*,modernize-use-override')
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-22 09:02:13 +01:00
Stefan Weil
a39db7e581 Replace remaining GenericVector by std::vector for src/unittest
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-18 15:40:47 +01:00
Stefan Weil
576c09bf31 Replace remaining STRING by std::string in unittest
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-03-15 09:11:41 +01:00
Egor Pugin
1d5b083447 [clang-format] Format unit tests. 2021-03-13 00:06:34 +03:00
Egor Pugin
9710bc0465 More std::vector. 2021-01-07 13:57:57 +03:00
Stefan Weil
fc4002dda8 Remove helpers.h from public API
Remove also outdated references to apitypes.h which no longer exists.

Signed-off-by: Stefan Weil <sw@weil.de>
2020-12-31 09:06:16 +01:00
Stefan Weil
f7d7aa6b95 Make tmp directory for all unit tests
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2020-12-30 18:17:58 +01:00
Stefan Weil
64e902ddf7 Remove genericvector.h from public API
Signed-off-by: Stefan Weil <sw@weil.de>
2020-12-28 21:03:29 +01:00
Egor Pugin
6cc00aa332 Improve some unit tests. 2020-12-28 01:11:13 +03:00
Stefan Weil
a61d7ac2ee Add / fix namespace tesseract for unittest
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2020-12-27 10:54:43 +01:00
Stefan Weil
7c77b40e8c unittest: Remove unused local variables
This fixes two compiler warnings:

    unittest/recodebeam_test.cc:318:11: warning: unused variable 'min_t' [-Wunused-variable]
    unittest/resultiterator_test.cc:478:36: warning: unused variable 'dZ' [-Wunused-const-variable]

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2020-06-29 16:19:23 +02:00
Stefan Weil
e3e7a9bf33 Use #include <tesseract/*.h> for unittest
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-10-29 18:01:18 +01:00
Stefan Weil
26ba7e2f81 Fix #include path of public headers for unittest
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-10-29 08:41:47 +01:00
Stefan Weil
eec9c96767 Remove member functions STRING::string and StringParam::string (continued)
Commit 994ec697d8 did not update unittest.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-09-25 10:07:51 +02:00
Stefan Weil
beec85e023 Remove UNICHARSET::load_from_inmemory_file and related code
The method was only used in unittest where it can be replaced by
UNICHARSET::load_from_file which also simplifies the code.

This allows removing the class InMemoryFilePointer and fixes a TODO.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-08-12 13:07:15 +02:00
Stefan Weil
2ba90f02cb unittest: Initialize non-static class members in RecodeBeamTest (CID 1402765)
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-07-10 16:52:27 +02:00
Stefan Weil
8e7b1119b5 Run more unittests with the user's locale
Hopefully this improves the test coverage.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2019-05-16 18:12:55 +02:00
Shree Devi Kumar
1ac76d8825 Partially fix and enable more unittests
Add more subtests to langmodel_test

Add more subtests to langmodel_test

fix and enable lstmtrainer_test

fix and enable some subtests from recodebeam_test

partial fix for resultiterator_test

fix typo removing the terminating linefeed.

fix typo

changes
2019-01-27 06:49:57 +00:00
Stefan Weil
4ec9c86226 unittest: Replace NULL by nullptr
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2018-09-29 09:27:12 +02:00
Stefan Weil
9e66fb918f unittest: Format code
It was formatted with clang-format-7 -i unittest/*.{c*,h}.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2018-09-29 09:19:13 +02:00
Stefan Weil
2b7df59187 Add more unittests from Google
They were provided by Jeff Breidenbach <jbreiden@google.com>.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2018-08-25 18:16:46 +02:00