Delphi - mORMot:安装出错。 UTF8 测试的自动测试错误!我该如何解决?
Delphi - mORMot : Installation went wrong. Automated Test Error on UTF8 test! How do I Fix this?
我将 mORMot 文件夹添加到 Delphi 的库中,并通过文件夹 SQLite3 中的 运行 TestSQL3 测试它是否正常工作。它在 UTF8
处显示错误
! - UTF8:14,000 / 1,099,792 失败 1.15s
我该如何解决这个问题?请帮忙!!提前谢谢你。
Synopse mORMot Framework Automated tests
- Synopse libraries
1.1. Low level common:
- System copy record: 162 assertions passed 108us
- TRawUTF8List: 190,172 assertions passed 61.62ms
- TDynArray: 1,092,815 assertions passed 137.96ms
- TDynArrayHashed: 1,599,067 assertions passed 1.09s
- TSynDictionary: 139,850 assertions passed 324.01ms
- TSynQueue: 6,541,501 assertions passed 215.78ms
- TObjectListHashed: 2,996,100 assertions passed 1.49s
- TObjectListSorted: 79,912 assertions passed 51.59ms
- TSynNameValue: 40,032 assertions passed 5.54ms
- TRawUTF8Interning: 2,000,013 assertions passed 122.39ms
500000 interning 8 KB in 40.91ms i.e. 12,219,262/s, aver. 0us, 186.4 MB/s
500000 direct 7.6 MB in 12.76ms i.e. 39,175,742/s, aver. 0us, 597.7 MB/s
- TObjectDynArrayWrapper: 167,501 assertions passed 13.25ms
- TObjArray: 3,230 assertions passed 1.72ms
- Custom RTL: 77,552 assertions passed 1s
FillChar in 30.56ms, 12.7 GB/s
Move in 4.51ms, 3.4 GB/s
small Move in 5.86ms, 3.7 GB/s
big Move in 106.81ms, 3.6 GB/s
FillCharFast [] in 33.54ms, 11.5 GB/s
MoveFast [] in 3.61ms, 4.3 GB/s
small MoveFast [] in 5.76ms, 3.8 GB/s
big MoveFast [] in 105.27ms, 3.7 GB/s
- Fast string compare: 71 assertions passed 268us
- IdemPropName: 216 assertions passed 207us
- Url encoding: 152 assertions passed 1.08ms
- GUID: 10,007 assertions passed 2.75ms
- ParseCommandArguments: 232 assertions passed 370us
- IsMatch: 4,250 assertions passed 2.27ms
- TExprParserMatch: 140 assertions passed 663us
- Soundex: 35 assertions passed 518us
- Numerical conversions: 2,545,159 assertions passed 351.35ms
100000 FloatToText in 16.49ms i.e. 6,062,443/s, aver. 0us, 109.9 MB/s
100000 str in 23.31ms i.e. 4,290,004/s, aver. 0us, 94 MB/s
100000 DoubleToShort in 18.31ms i.e. 5,460,899/s, aver. 0us, 99 MB/s
- Integers: 33,860 assertions passed 48.08ms
- crc32c: 290,087 assertions passed 80.93ms
pas 286.7 MB/s fast 2.4 GB/s sse42 4.1 GB/s
- Random32: 201,002 assertions passed 25.81ms
- Bloom filters: 2,010,072 assertions passed 128.92ms
- DeltaCompress: 87 assertions passed 6.38ms
- Curr 64: 20,056 assertions passed 1.83ms
- CamelCase: 11 assertions passed 116us
- Bits: 22,985 assertions passed 14.47ms
- Ini files: 7,028 assertions passed 188.97ms ! - UTF8: 14,000 / 1,099,792 FAILED 1.15s
- Url decoding: 1,101 assertions passed 561us
- Baudot code: 10,007 assertions passed 21.87ms
- Iso 8601 date and time: 200,831 assertions passed 16.80ms
- Time zones: 408 assertions passed 212.13ms
- Mime types: 30 assertions passed 651us
- Quick select: 4,015 assertions passed 124.33ms
- TSynTable: 875 assertions passed 2.34ms
- TSynCache: 404 assertions passed 404us
- TSynFilter: 1,005 assertions passed 2.57ms
- TSynValidate: 677 assertions passed 774us
- TSynLogFile: 49 assertions passed 977us
- TSynUniqueIdentifier: 1,300,002 assertions passed 515.62ms Total failed: 14,000 / 22,692,553 - Low level common FAILED 7.45s
Windows 10 64bit (10.0.18362) (cp874)
8 x Intel(R) Core(TM) i5-9300H CPU @ 2.40GHz (x86) Using mORMot 1.18.6102
TSQLite3LibraryStatic 3.32.3 with internal MM Generated with: Delphi 10.3 Rio 32 bit compiler
Time elapsed for all tests: 2m29 Performed 2020-08-06 23:58:11 by
LENOVO on LAPTOP-BED954TL
Total assertions failed for all test suits: 14,000 / 45,919,717 !
Some tests FAILED: please correct the code.
Done - Press ENTER to Exit
回归测试存在限制。
正如您的输出状态:
Windows 10 64bit (10.0.18362) (cp874)
您使用的系统 Code Page 874。
在一些测试中,WinAnsi 的一些 UTF-8 - 又名 code page 1252 - 通过 AnsiString
类型执行,并且您自己的代码页可能会丢失一些字符。
因此报告了一些测试失败。
由于当前测试的一些限制,这是一个误报错误。以后我会尽量避免这样的问题。
如果您可以编译 TestSQL3
那么很可能 您的安装是正确的,并且它将按预期使用内部 UTF-8 内容(mORMot 工作内部使用 UTF-8 JSON 以避免不必要的转换),而常规 VCL string
类型,即 UTF-16,将通过 UTF8ToString/StringToUTF8()
函数安全地可用。
我将 mORMot 文件夹添加到 Delphi 的库中,并通过文件夹 SQLite3 中的 运行 TestSQL3 测试它是否正常工作。它在 UTF8
处显示错误! - UTF8:14,000 / 1,099,792 失败 1.15s
我该如何解决这个问题?请帮忙!!提前谢谢你。
Synopse mORMot Framework Automated tests
- Synopse libraries
1.1. Low level common:
- System copy record: 162 assertions passed 108us
- TRawUTF8List: 190,172 assertions passed 61.62ms
- TDynArray: 1,092,815 assertions passed 137.96ms
- TDynArrayHashed: 1,599,067 assertions passed 1.09s
- TSynDictionary: 139,850 assertions passed 324.01ms
- TSynQueue: 6,541,501 assertions passed 215.78ms
- TObjectListHashed: 2,996,100 assertions passed 1.49s
- TObjectListSorted: 79,912 assertions passed 51.59ms
- TSynNameValue: 40,032 assertions passed 5.54ms
- TRawUTF8Interning: 2,000,013 assertions passed 122.39ms 500000 interning 8 KB in 40.91ms i.e. 12,219,262/s, aver. 0us, 186.4 MB/s 500000 direct 7.6 MB in 12.76ms i.e. 39,175,742/s, aver. 0us, 597.7 MB/s
- TObjectDynArrayWrapper: 167,501 assertions passed 13.25ms
- TObjArray: 3,230 assertions passed 1.72ms
- Custom RTL: 77,552 assertions passed 1s FillChar in 30.56ms, 12.7 GB/s Move in 4.51ms, 3.4 GB/s small Move in 5.86ms, 3.7 GB/s big Move in 106.81ms, 3.6 GB/s FillCharFast [] in 33.54ms, 11.5 GB/s MoveFast [] in 3.61ms, 4.3 GB/s small MoveFast [] in 5.76ms, 3.8 GB/s big MoveFast [] in 105.27ms, 3.7 GB/s
- Fast string compare: 71 assertions passed 268us
- IdemPropName: 216 assertions passed 207us
- Url encoding: 152 assertions passed 1.08ms
- GUID: 10,007 assertions passed 2.75ms
- ParseCommandArguments: 232 assertions passed 370us
- IsMatch: 4,250 assertions passed 2.27ms
- TExprParserMatch: 140 assertions passed 663us
- Soundex: 35 assertions passed 518us
- Numerical conversions: 2,545,159 assertions passed 351.35ms 100000 FloatToText in 16.49ms i.e. 6,062,443/s, aver. 0us, 109.9 MB/s 100000 str in 23.31ms i.e. 4,290,004/s, aver. 0us, 94 MB/s 100000 DoubleToShort in 18.31ms i.e. 5,460,899/s, aver. 0us, 99 MB/s
- Integers: 33,860 assertions passed 48.08ms
- crc32c: 290,087 assertions passed 80.93ms pas 286.7 MB/s fast 2.4 GB/s sse42 4.1 GB/s
- Random32: 201,002 assertions passed 25.81ms
- Bloom filters: 2,010,072 assertions passed 128.92ms
- DeltaCompress: 87 assertions passed 6.38ms
- Curr 64: 20,056 assertions passed 1.83ms
- CamelCase: 11 assertions passed 116us
- Bits: 22,985 assertions passed 14.47ms
- Ini files: 7,028 assertions passed 188.97ms ! - UTF8: 14,000 / 1,099,792 FAILED 1.15s
- Url decoding: 1,101 assertions passed 561us
- Baudot code: 10,007 assertions passed 21.87ms
- Iso 8601 date and time: 200,831 assertions passed 16.80ms
- Time zones: 408 assertions passed 212.13ms
- Mime types: 30 assertions passed 651us
- Quick select: 4,015 assertions passed 124.33ms
- TSynTable: 875 assertions passed 2.34ms
- TSynCache: 404 assertions passed 404us
- TSynFilter: 1,005 assertions passed 2.57ms
- TSynValidate: 677 assertions passed 774us
- TSynLogFile: 49 assertions passed 977us
- TSynUniqueIdentifier: 1,300,002 assertions passed 515.62ms Total failed: 14,000 / 22,692,553 - Low level common FAILED 7.45s
Windows 10 64bit (10.0.18362) (cp874) 8 x Intel(R) Core(TM) i5-9300H CPU @ 2.40GHz (x86) Using mORMot 1.18.6102 TSQLite3LibraryStatic 3.32.3 with internal MM Generated with: Delphi 10.3 Rio 32 bit compiler
Time elapsed for all tests: 2m29 Performed 2020-08-06 23:58:11 by LENOVO on LAPTOP-BED954TL
Total assertions failed for all test suits: 14,000 / 45,919,717 ! Some tests FAILED: please correct the code.
Done - Press ENTER to Exit
回归测试存在限制。
正如您的输出状态:
Windows 10 64bit (10.0.18362) (cp874)
您使用的系统 Code Page 874。
在一些测试中,WinAnsi 的一些 UTF-8 - 又名 code page 1252 - 通过 AnsiString
类型执行,并且您自己的代码页可能会丢失一些字符。
因此报告了一些测试失败。
由于当前测试的一些限制,这是一个误报错误。以后我会尽量避免这样的问题。
如果您可以编译 TestSQL3
那么很可能 您的安装是正确的,并且它将按预期使用内部 UTF-8 内容(mORMot 工作内部使用 UTF-8 JSON 以避免不必要的转换),而常规 VCL string
类型,即 UTF-16,将通过 UTF8ToString/StringToUTF8()
函数安全地可用。