Tarek Mahmoud Sayed
ff964b2700
Merge pull request dotnet/corefx#8125 from hughbe/decoder-neg-tests
...
Add/Cleanup GetDecoder negative tests
Commit migrated from https://github.com/dotnet/corefx/commit/c489a24fa5f6993013852c5e948ba7c4bd45950b
2016-04-27 17:38:15 -07:00
Hugh Bellamy
088cceb472
Add Latin1Encoding tests
...
- Decode, Encode
- GetMaxCharCount, GetMaxByteCount
- GetPreamble, Clone, Equals
- EncoderFallback, DecoderFallback
- CodePage, WebName, EncodingName, IsSingleByte
Also fixes up the NegativeEncodingTests to not hardcode specific
Encodings
Contributes to dotnet/corefx#8114
Commit migrated from https://github.com/dotnet/corefx/commit/8714473001b21a33a173e72617d0abac7fc8999d
2016-04-27 20:47:25 +01:00
Hugh Bellamy
e0f8e7ac31
Add/Cleanup GetDecoder negative tests
...
- Move to new more modern file
Commit migrated from https://github.com/dotnet/corefx/commit/f8ceb79cb292296b3fd00fd55638fdea03de4a64
2016-04-27 17:56:44 +01:00
Tarek Mahmoud Sayed
654fb285b4
Merge pull request dotnet/corefx#8103 from hughbe/ascii-encoder-decoder-fallback
...
Add tests for EncoderFallback and DecoderFallback in ASCIIEncoding
Commit migrated from https://github.com/dotnet/corefx/commit/3a3ee66d5b9b0cec13b230432bf2757f4c4976c2
2016-04-27 08:40:41 -07:00
Hugh Bellamy
4e663948b2
Add tests for EncoderFallback and DecoderFallback in ASCIIEncoding
...
Commit migrated from https://github.com/dotnet/corefx/commit/4b5eafc330a6193e9e8778a1ef1bd0d74d8c43e0
2016-04-26 21:36:16 +01:00
Hugh Bellamy
1ff616a43f
Add/cleanup GetEncoder negative tests
...
Commit migrated from https://github.com/dotnet/corefx/commit/0420655f376d2c7f4c332d881c7f12b3f3f7da0d
2016-04-26 19:01:14 +01:00
Hugh Bellamy
b6726b24ab
Address PR feedback, fix failing test
...
Commit migrated from https://github.com/dotnet/corefx/commit/6dc578756444304fcaf1929df24edf82f1cc7632
2016-04-25 23:04:13 +01:00
Hugh Bellamy
82e6681aed
Add UTF32 tests
...
- Encoding and decoding valid chars and bytes
- Other methods
- Ctors
- Properties
Commit migrated from https://github.com/dotnet/corefx/commit/273c114e0877d4d38d901dc76610fd8e2e465a0c
2016-04-25 23:04:13 +01:00
Tarek Mahmoud Sayed
8ec7060a56
Merge pull request dotnet/corefx#8009 from hughbe/utf8-fallback
...
Add tests for EncoderFallback and DecoderFallback for UTF8Encoding
Commit migrated from https://github.com/dotnet/corefx/commit/d5edefbdbb9bd6f07fb32194fd41498b68335233
2016-04-25 08:47:16 -07:00
Hugh Bellamy
65029542c3
Add more negative tests to System.Text.Encoding
...
- Null byte[] in GetBytes()
- Make sure GetMaxByteCount and GetMaxCharCount respect the MaxCharCount
property of EncoderFallback and DecoderFallback
Commit migrated from https://github.com/dotnet/corefx/commit/dd9b6990ace8e90ef557626e2e66c4a6061ad351
2016-04-24 13:09:04 +01:00
Hugh Bellamy
5893251aea
Address PR feedback
...
Commit migrated from https://github.com/dotnet/corefx/commit/a001630534cfda2e028831e978a215663687f940
2016-04-23 08:58:05 +01:00
Hugh Bellamy
a89728737e
Add tests for EncoderFallback and DecoderFallback for UTF8Encoding
...
- Also adds a helper method to NegativeEncodingTests to verify
DecodeFallbackExceptions and EncoderFallback exceptions are thrown
Commit migrated from https://github.com/dotnet/corefx/commit/c7b17abe866fe919fa84e407372e6ab7ab1e8b8d
2016-04-22 23:45:12 +01:00
Hugh Bellamy
1e9619a74c
Move legacy UnicodeEncoding tests to modern files
...
- Take advantage of EncodingTestHelpers and NegativeEncodingTestHelpers
to remove boilerplate and duplicated code/tests (e.g. we don't need to
test data for all overloads or GetCharCount/GetByteCount as the helpers
handle this for us)
- Move encode and decode tests to the new files
Commit migrated from https://github.com/dotnet/corefx/commit/fc607f9119c24939aa78af0f0908fe54fc5f271f
2016-04-22 18:20:12 +01:00
Hugh Bellamy
47a2a9b7af
Move legacy UTF8Encoding tests to modern files
...
- Take advantage of EncodingTestHelpers and NegativeEncodingTestHelpers
to remove boilerplate and duplicated code/tests
- Move encode and decode tests to the new files
Commit migrated from https://github.com/dotnet/corefx/commit/96cb298952e09ad7adbd52c6050673187ce1c3b8
2016-04-21 22:36:48 +01:00
Hugh Bellamy
5a22741170
Add negative tests for unsafe encoding and decoding
...
Commit migrated from https://github.com/dotnet/corefx/commit/0a7d12706d64fb1b7f335e477791a690edbf64a8
2016-04-21 16:53:15 +01:00
Hugh Bellamy
e834661e13
Address PR feedback
...
Commit migrated from https://github.com/dotnet/corefx/commit/f036a4aed44575fdf3a33a0bde293d1f4fe9c64f
2016-03-25 22:42:16 +00:00
Hugh Bellamy
c48fd59e48
Cleanup ASCIIEncoding tests
...
Use common helper that contains more tests than before
Commit migrated from https://github.com/dotnet/corefx/commit/a2a7bb46b9580677b0ab45d0ff965233b9af2b1a
2016-03-25 22:14:44 +00:00
Hugh Bellamy
e9c2c9a502
Add a couple more NegativeEncoding tests
...
Commit migrated from https://github.com/dotnet/corefx/commit/52fcf70e64a0b07ca2b4920dd311c705714428c7
2016-03-24 20:48:50 +00:00
Hugh Bellamy
1fbd1a85f3
Cleanup UTF8Encoding negative tests
...
Commit migrated from https://github.com/dotnet/corefx/commit/941cd1ba251d954a0ebdbeeac1f301e8ce852d11
2016-03-24 19:45:15 +00:00
Hugh Bellamy
4350cb6024
Cleanup UTF7Encoding negative tests
...
- Make EncodingHelpers.cs more extensible
Commit migrated from https://github.com/dotnet/corefx/commit/2d49ba5a5d904ddd8a750fdd26e82089ca05a58f
2016-03-23 08:05:41 +00:00