Commit Graph
18 Commits
Author SHA1 Message Date
Hugh Bellamy fcbd2163a9 Move legacy ASCIIEncoding tests to the modern files
- Also removes some old tests that are now duplicates and were undeleted
due to the recent cleanup


Commit migrated from https://github.com/dotnet/corefx/commit/1ee307e8fd52aaecdf6c920c38c08c73514916b5
2016-04-23 00:13:58 +01:00
Hugh Bellamy f15da2ff38 Remove random data from System.Text.Encoding tests
Commit migrated from https://github.com/dotnet/corefx/commit/c8dd21919875419202bbf8277b776580c783b6aa
2016-04-21 21:32:38 +01:00
Hugh Bellamy 0ddf973612 Add AsciiEnccoding tests
- Invalid bytes
- Valid surrogate pairs
- Invalid surrogate pairs
- Invalid chars


Commit migrated from https://github.com/dotnet/corefx/commit/7f7621f597c65b30ae7be93a28f73e2283726b90
2016-04-21 16:57:58 +01:00
Hugh Bellamy ce20775029 Add UTF8Encoding tests
- All ASCII chars
- Valid surrogate pairs
- Invalid surrogate pairs
- Invalid unicode chars
- Invalid bytes
- Change Decode(..., char[]) to Decode(..., string) for convenience


Commit migrated from https://github.com/dotnet/corefx/commit/96326160e8979c97bcc77e28a2e0c8960f4f45f7
2016-04-20 21:43:10 +01:00
Hugh Bellamy e64fce918c Consolidate GetByteCount/GetByte and GetChars/GetCharCount/GetString tests
- Less test code duplication


Commit migrated from https://github.com/dotnet/corefx/commit/1879fbb6fcc4dc5dd83a0458b28302e58d3868eb
2016-04-16 10:50:19 +01:00
Stephen Toub 4cfbce5bbd Merge pull request dotnet/corefx#7385 from hughbe/bolster-encoding-helpers
Actually test GetBytes and GetChars in System.Text.Encoding

Commit migrated from https://github.com/dotnet/corefx/commit/edda8320a56a7080874ee37f190dbaa28a74aaff
2016-04-01 07:36:47 -04:00
Hugh Bellamy 2540ee56b3 Address PR feedback
Commit migrated from https://github.com/dotnet/corefx/commit/609e9ab66c7ff6332665fe75dd7cfd1649daaed3
2016-03-31 18:13:04 +01:00
Hugh Bellamy f2aa24fa36 Add a test for GetPreamble to ASCIIEncoding
More consistent with other encoding tests


Commit migrated from https://github.com/dotnet/corefx/commit/594e788d21006d680125bfb728d4aca5ffb3249c
2016-03-31 11:51:35 +01:00
Hugh Bellamy 5afc5d0c67 Actually test GetBytes and GetChars in System.Text.Encoding
- Previous tests for GetBytes and GetChars did not test anything apart
from the return value: the method could've created any byte[] or char[]
result and we wouldn't have verified it.
- Also adds more coverage by testing more overloads of GetBytes and
GetChars


Commit migrated from https://github.com/dotnet/corefx/commit/2bd77a8c5f104624f403cb48c0bfabcdb9beaaf8
2016-03-31 11:34:56 +01: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
Jon Hanna e0d1ada9bb Fix Multiple Typos [7]
Commit migrated from https://github.com/dotnet/corefx/commit/1ad3dfd20e56dab48384063f07e13f72d1dbcf96
2016-03-20 19:10:51 +00:00
Jon Hanna 109feb6662 Fix multiple typos.
Commit migrated from https://github.com/dotnet/corefx/commit/3e57029abfd9b205857460b89b9907ccaac4a249
2016-03-20 14:55:31 +00:00
Hugh Bellamy e5969d18a5 PR feedback
Commit migrated from https://github.com/dotnet/corefx/commit/36c02ae3445b2910398d68dd2e474fe92a9c6c9a
2016-02-28 23:54:49 +00:00
Hugh Bellamy 8540b84cc3 Cleanup ASCIIEncoding tests
- Rename tests to follow guidelines, instead of "PosTest1" and
"NegTest2"
- Take advantage of xunit
- Shorten tests by using quicker and newer code


Commit migrated from https://github.com/dotnet/corefx/commit/3fdec68d88d2d5ce9eafc988c3a42158e5b50f70
2016-02-27 15:42:51 +00:00
dotnet-bot 39d1eab950 Update licensing headers
Commit migrated from https://github.com/dotnet/corefx/commit/7cad8486cbabbce0236bdf530e30db7036335524
2016-01-27 08:02:28 -08:00
Stephen A. Imhoff bc392f1c9f Update test namespace in System.Text.Encoding, per dotnet/corefx#2898 .
- Add namespace in lone file.
 - Clean up `using`s.


Commit migrated from https://github.com/dotnet/corefx/commit/72f17d002e22670de2d1b9a6528f451715969aaf
2015-10-02 16:35:35 +09:00
stephentoub ae493cc005 Fix System.Text.Encoding tests to use non-static RNG
Commit migrated from https://github.com/dotnet/corefx/commit/1b5d9fb7503cc01a6fba08b5d9bf0eb9cfb031b6
2015-07-14 22:15:30 -04:00
Venkatraman Mahalingam e157c69bbc Porting System.Text.Encoding from ToF and unified 4.0 and 4.10 tests into same folder
[tfs-changeset: 1474146]


Commit migrated from https://github.com/dotnet/corefx/commit/1394fa1c2539f289916b9c0641f81436b73e8794
2015-05-21 15:22:44 -07:00