Commit Graph
306 Commits
Author SHA1 Message Date
Alexander Radchenko eeda23bfed Fixed netfx System.Runtime.Serialization.Formatters.Tests fails on non-English Windows (dotnet/corefx#28386)
Commit migrated from https://github.com/dotnet/corefx/commit/f3768a7ee2726d0c070bc8c0bd8873d6cc52df7e
2018-03-22 23:01:05 -04:00
Anirudh Agnihotry 7ea972a654 Support added for 2.0 and 2.1 blobs (dotnet/corefx#27399)
Commit migrated from https://github.com/dotnet/corefx/commit/6c5a24394309297e03581cd72daefe83ea5f0903
2018-03-02 23:52:50 -08:00
Viktor Hofer 7dea4811b6 Enable blob comparison for TimeZoneInfo* & fix comment (dotnet/corefx#26647)
Commit migrated from https://github.com/dotnet/corefx/commit/541582ae4a1a861ffd3f280bbcf537a77a6337cb
2018-02-24 17:45:56 -08:00
Anirudh Agnihotry 7552566520 Tests for StringComparer Create(culture, CompareOptions) overload (dotnet/corefx#27051)
Commit migrated from https://github.com/dotnet/corefx/commit/e2fc82a68ba26767c2b0aa8e766573c32a422088
2018-02-23 10:38:19 -08:00
dotnet-maestro-bot 3561fd513c Update BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview2-02521-03, preview2-26221-06, preview2-26221-05, preview2-26220-02, beta-26221-00, beta-26221-00, respectively (master) (dotnet/corefx#27289)
* Update BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview2-02521-03, preview2-26221-06, preview2-26221-05, preview2-26220-02, beta-26221-00, beta-26221-00, respectively

* Fix test data for System.Runtime.Serialization.Formatters BinFormatTestData


Commit migrated from https://github.com/dotnet/corefx/commit/c6983b1597e0ab722082845519d3c8af9029e27f
2018-02-21 13:12:48 -08:00
Santiago Fernandez Madero b317fa70f6 Add System.Security.Permissions netfx facade and mark some APIs as obsolet to match desktop (dotnet/corefx#26758)
* Add System.Security.Permissions netfx facade and mark some APIs as obsolet to match desktop

* PR Feedback


Commit migrated from https://github.com/dotnet/corefx/commit/2ef483fd4aab623e54379be1292999c1fb39a3fa
2018-02-05 14:08:26 -08:00
Viktor Hofer 5697ca8910 Add tests for EventArgs serialization (dotnet/corefx#25940)
* Add tests for EventArgs serialization

* Add EventArgs equality check as the type doesn't provide its own check


Commit migrated from https://github.com/dotnet/corefx/commit/b1737de9d53386da84cff232304f7143b0998d47
2018-01-02 20:42:28 +01:00
Santiago Fernandez Madero f230741a96 Change PlatformDetection.GetFrameworkVersion() to use registry key value instead of minor build number (dotnet/corefx#26094)
* Change PlatformDetection.GetFrameworkVersion() to use registry key value instead of minor build number

* Address PR Feedback to do one liner getters


Commit migrated from https://github.com/dotnet/corefx/commit/0a131dd2dd4d408c47946a0928f5a9f2d709f6db
2017-12-30 02:02:03 -06:00
Jon Hanna 5ecc221cc7 Add license headers. (dotnet/corefx#26009)
Any *.cs file found without the usual license header has it added except:

1. Files that note they are auto-generated.
2. Files with a different header (unless it is very close to the usual,
in which case adjust for typos and old versions).
3. FxCopBaseline.cs files.

Commit migrated from https://github.com/dotnet/corefx/commit/e5da05d7100a64ab1d98c865436a1fb8b0ddd507
2017-12-22 12:51:37 -06:00
stukselbax d752530099 Making Win32Exception.ToString() method contain NativeErrorCode (dotnet/corefx#25216)
* Making Win32Excpetion.ToString() method more useful by adding NativeErrorCode

* Cache StackTrace to local variable

* corefx-24892 Change binary formater test data for WebSocketException and the string representation of Win32Exception

* corefx-24892 Add condition for full framework in test


Commit migrated from https://github.com/dotnet/corefx/commit/272b278727e5654f41a218779793132f92404fa1
2017-12-15 15:25:54 -08:00
Viktor Hofer e0403c3222 Add composition assembly to rd.xml to unblock reflection on exceptions (dotnet/corefx#25683)
Commit migrated from https://github.com/dotnet/corefx/commit/beefd9ab059f66988133e0821a08f80b705a683c
2017-12-04 13:42:29 -08:00
Viktor Hofer 72b37071cd Improve BinaryFormatter equality check logging (dotnet/corefx#25566)
* Improve Exception Assert logging

* Replace manual equality checks with Assert

* Add more test coverage for exceptions

* code style

* exclude two networking type checks


Commit migrated from https://github.com/dotnet/corefx/commit/fa80bd2e123652c1cba4fdbc9169f10aa9c1b2cd
2017-11-29 20:32:01 -08:00
Maryam Ariyan a63ea85fb5 Porting first half of the System.ComponentModel.Composition tests (dotnet/corefx#25437)
* Adding a portion of System.ComponentModel.Composition tests

Commit migrated from https://github.com/dotnet/corefx/commit/fed2d5ff6842b2ce932c70162f3e06a8d0304030
2017-11-28 20:07:39 -08:00
Viktor Hofer 6d031c559a Fix UpdateBlobs regression, reenabling ValueTuple tests on Core, add Dictionary<string,string> serialization test case (dotnet/corefx#24962)
* Fix UpdateBlobs regression, reenabling ValueTuple tests on Core

* Add Dictionary<string,string> serialization test case


Commit migrated from https://github.com/dotnet/corefx/commit/b2dcf2c4c392b228ce7a35a7d1873eab0846ab9e
2017-11-03 16:41:57 +01:00
Santiago Fernandez Madero c07313de19 Fix system formatter tests hitting netfx inbox binplace issue (dotnet/corefx#24935)
* Fix Serialization.Formatter tests hitting PNSE in DirectoryServices.Protocols

* Fix Serialization.Formatter tests hitting PNSE in DirectoryServices.AccountManagement

* Fix Serialization.Formatter tests hitting PNSE in DirectoryServices


Commit migrated from https://github.com/dotnet/corefx/commit/853d4c4b66d010ab430a2454c9c6fe95e6dffd78
2017-10-27 23:19:10 -07:00
Viktor Hofer fcc00e81f3 Make corefx exceptions serializable and add typeforwards (dotnet/corefx#24427)
* Add serializable attribute and typeforward and adding serialization impl
* Expose ZLibException in impl assembly
* Remove deserialization negative tests
* Adding tests for exceptions
* Adding SqlError data to base exception data table
* System Data Facade
* Add netfx471 blob diffs for Hashtable and ListDictionary
* Build Microsoft.NETCore.App.deps.json after manual shims
* Disable currently failing uap/uapaot tests because of shim assembly load errors


Commit migrated from https://github.com/dotnet/corefx/commit/e3f74deb999571d3f34a6b2b8011caebcf06dbfc
2017-10-27 18:00:52 +02:00
Stephen Toub fc2f8b26e9 Use stackalloc directly into Span (dotnet/corefx#24212)
* Use stackalloc directly into Span

We have a few places in corefx where we were stackalloc'ing into a temporary pointer and then creating a Span from that.  Now that we're using a C# compiler which supports stackalloc'ing directly into span, use that feature instead.

* Address PR feedback


Commit migrated from https://github.com/dotnet/corefx/commit/a7f6f470cb2c4cdaafdc3ad85e2520992a8db265
2017-09-24 09:45:07 -04:00
Jose Perez Rodriguez 1085964bcc Updating corefx to use new roslyn compiler (dotnet/corefx#24076)
* Updating corefx to use new roslyn compiler

* Updating to new version of the compiler and use the switch so tests pass on desktop

* Fix System.Reflection.Metadata tests


Commit migrated from https://github.com/dotnet/corefx/commit/fc4b1adb7f06687aa15f0416d83d2c27a0abf8dd
2017-09-18 17:02:24 -07:00
Viktor Hofer 1b6e77f562 Cleanup code in System.Runtime.Serialization.Formatters.Tests (dotnet/corefx#23940)
* Cleanup code in System.Runtime.Serialization.Formatters.Tests

* Moved UnitySerializationHolder serialization test to System.Runtime.Tests


Commit migrated from https://github.com/dotnet/corefx/commit/705dc4196a6139b70dcf818c109b01aa295edcb1
2017-09-12 12:29:54 +02:00
Viktor Hofer b225d65a55 Adding dbnull to dbtable (dotnet/corefx#23959)
Commit migrated from https://github.com/dotnet/corefx/commit/15c191b29a5efb4d5dbc59784feb7af54ddbe8d5
2017-09-11 16:38:42 -07:00
Viktor Hofer dc54c019f7 DbNull serialization with tests and forward (dotnet/corefx#23897)
* DbNull tests and forward

* UnitySerializationHolder deserialization test added


Commit migrated from https://github.com/dotnet/corefx/commit/9ab8189268fbc6c4e98f8d10a6753d0477ef3239
2017-09-11 22:49:26 +02:00
Viktor Hofer 6704d84939 Fixing uap serialization errors for exceptions (dotnet/corefx#23808)
* Fixing uap serialization errors for exceptions

* pr changes

* Revert two updated blobs


Commit migrated from https://github.com/dotnet/corefx/commit/c89b4fb5050d9ca3de86dddce7fe3fd9dc34dc33
2017-09-06 01:34:07 +02:00
Viktor Hofer 2e4c798b3c Adding cross framework serialization and blob sanity check for serializable Exception types (dotnet/corefx#23523)
* Adding cross framework serialization and blob sanity check for serializable Exception types

* Add AggregateException equality check and check InnerException of Exception type

* Refine test data for exceptions

* Manual StackTrace override for Exception serialization tests

* Improved exception serialization data


Commit migrated from https://github.com/dotnet/corefx/commit/a534c0ebbd3c5741f97590ece32f1b31645f0994
2017-08-25 01:57:55 +02:00
Viktor Hofer 24ff7a5172 Set InvariantCulture Local explicitely and improve error logging (dotnet/corefx#23486)
* Set InvariantCulture Local explicitely and improve error logging

Commit migrated from https://github.com/dotnet/corefx/commit/dd8bc0d9e929ff4a7da368ae1c16b9b33e9c8a6a
2017-08-23 15:04:13 +02:00
Viktor Hofer b1ef95a563 Setting culture to Invariant to avoid not installed user language on test machines (dotnet/corefx#23391)
Commit migrated from https://github.com/dotnet/corefx/commit/c61981dc5b87ac3f389a4c63ed97dae9dde37c77
2017-08-18 15:44:15 -07:00
Viktor Hofer 1cd45647ed Set fixed culture for CookieContainer blob sanity check (dotnet/corefx#23285)
* Set fixed culture for CookieContainer blob sanity check

* PR feedback


Commit migrated from https://github.com/dotnet/corefx/commit/04c1a2ce4e9eb46f229038961e99702336780b06
2017-08-17 12:41:33 -04:00
Tarek Mahmoud Sayed 3765a6069b Moving PlatformDetection to Corefx.Private.TestUtilities assembly (dotnet/corefx#23109)
* Moving PlatformDetection to Corefx.Private.TestUtilities assembly

The purpose of this change is to clean up all test projects instead of including the PlatformDetection code inside every test project, we’ll have it in the Corefx.Private.TestUtilities.
I have refactored the PlatformDetection to split the different implementation of Windows and Linux. If we need to do more refactoring there we can do it later as needed.

* Fix Linux BB

* Update the xunit package reference

* Fix wrong condition on one of the tests

* Update the ConditionalFact/Theory to use Type as a parameter


Commit migrated from https://github.com/dotnet/corefx/commit/878e2fcf5a9f1068015e5fada9231088663e3490
2017-08-10 22:37:36 -07:00
Viktor Hofer 06e660f0a0 Disabling adjustmentrule blob sanity check till code is converged
Commit migrated from https://github.com/dotnet/corefx/commit/ae66307e238461bc243a9b8dc231ffeb5c2f76f2
2017-07-21 11:57:11 -07:00
Morgan Brown ec6630c262 Fix BinaryFormatter AoT test differences (dotnet/corefx#22461)
* Fix serialization tests to handle a couple of AoT differences:
1. AoT doesn't return ByteEqualityComparer from EqualityComparer<byte>.Default, so create it with reflection instead
2. CoreCLR changes the _version field of List differently than both AoT and NetFX, so pass arrays to the IEnumerable constructor of a few collections, which causes the _version fields to agree. Also updates the stored blobs to reflect this.


Commit migrated from https://github.com/dotnet/corefx/commit/7639beea9ff8be752b46bbe084093cd43bec6e35
2017-07-20 11:47:52 -07:00
Viktor Hofer 859e71c936 Update blobs after coreclr incoming change with TypeForward rename
Commit migrated from https://github.com/dotnet/corefx/commit/53801e55ee02d688b93102cac834fcd5a3a50631
2017-07-10 13:36:40 +02:00
Viktor Hofer f4032764bb Update blobs after typeforward rename
Commit migrated from https://github.com/dotnet/corefx/commit/f8e87b08ca911d116a802f0fe48ac15033f48a61
2017-07-09 21:51:01 +02:00
Morgan Brown 7b8503d009 Fixes UAPAOT compilation for the System.Runtime.Serialization.Formatters test, which fails because a test struct has a field of type Span, but isn't marked IsByRefLike. (dotnet/corefx#21839)
Commit migrated from https://github.com/dotnet/corefx/commit/f6ee8e88a54ff3ddb636f643f7691fca94ccfcb3
2017-07-03 18:35:36 -07:00
Hugh Bellamy 98b18432b7 Move AssertExtensions to Corefx.Private.TestUtilities (dotnet/corefx#21799)
* Move AssertExtensions to Corefx.Private.TestUtilities

* Update csprojs

* Fix Linq.Expressions uapaot build


Commit migrated from https://github.com/dotnet/corefx/commit/7e3b0db2892c56a431f8e99af9cd9381adec385a
2017-07-03 09:27:30 -07:00
Hugh Bellamy 7cdcaf5fc5 Convert Assert.Throws<ArgumentException> to AssertExtensions (dotnet/corefx#21491)
Commit migrated from https://github.com/dotnet/corefx/commit/868f123881e520285ab09600380e38abdd457a06
2017-06-27 21:13:26 -07:00
Hugh Bellamy 9058da92aa Correctly handle empty strings in params of RemoteExecutorTestBase (dotnet/corefx#21196)
* Implement argument pasting in RemoteInvoke

* Add tests for RemoteInvoke fixes

* Update RemoteInvoke tests now that quoting is unecessary

* Fix netfx tests

The extra parameter is empty in netfx so was pasted to ""

* Address PR feedback


Commit migrated from https://github.com/dotnet/corefx/commit/232f48884efed22d228ae4a9450b37fbfa92b861
2017-06-27 19:12:14 -07:00
Viktor Hofer 070a2b2fa3 SQLString adding missing typeforward to correctly serializable blobs between netfx and core (dotnet/corefx#21564)
Commit migrated from https://github.com/dotnet/corefx/commit/a85e94918154e43f3d5747a02db5deb85dae6873
2017-06-26 17:22:00 +02:00
Viktor Hofer da98b64432 [WIP] BinaryFormatter - Reenable sanity check (dotnet/corefx#21507)
* Reenable sanity check

* Avoid different blobs for CookieContainer dependent on machine configuration

* Fixing diffent blobs for CompareInfo as it used machine config depdent values

* Fixing different in DataTable and DataSet

* Fixing CookieCollection missing field in serialization


Commit migrated from https://github.com/dotnet/corefx/commit/3ba241487054331c32ca5c1c13426de37ddd97c3
2017-06-25 09:26:33 +02:00
Hugh Bellamy 7cbcd5ed85 Convert most Assert.Throws<ArgumentException> without param name to AssertExtensions (dotnet/corefx#21455)
* Registry

* Collections

* ComponentModel

* Configuration

* Data

* Globalization

* Drawing

* Diagnostics

* IO

* Linq

* Add System.Net param names in tests

* Move ArgumentExceptions in System.Private.Xml to AssertExtensions

* Add System.Reflection.* ArgumentException param names

* Add param names for System.Runtime* ArgumentExceptions

* Add ArgumentException param names to System.Security.*

* Add ArgumentException param names to System.Text.*

* Add param names to ArgumentExceptions in misc projects

* Add System.Threading.* ArgumentException param names

* Fix missing files

* Fixes for unix and netfx

* Fix more failures and revert a IdnaConformance tests to avoid merge conflicts with dotnet/corefx#21463


Commit migrated from https://github.com/dotnet/corefx/commit/59915687bb261efeae70565d0ca8990ac45ceb9c
2017-06-23 12:33:47 -07:00
Dan Moseley 6a6bd7e1cc Fix XmlSchemaSet tests for UAP (dotnet/corefx#21418)
* Fix XmlSchemaSet tests for UAP

* Fix binaryformattertests


Commit migrated from https://github.com/dotnet/corefx/commit/3d933993408db040a8844caf7cdd14582e81af40
2017-06-22 23:54:21 -07:00
Viktor Hofer 83f120531c Fixing SizeF, CookieContainer, CookieCollection serialization between Core <--> Desktop and adding full binary mode tests (dotnet/corefx#21223)
* Adding TypeForward to PathListComparer, CookieCollection member, full-mode tests, SizeF publickeytoken fix

* Making FormatterAssemblyStyle explicit

* Update blobs after CompareInfo culture field added to serialization payload

* Added blob integrity check

* Remove unnecessary operation which has no impact on netfx serialization

* Putting pragma around the unused field...

* Setting m_version value to include it in the serialization payload. Remove static versions for blob comparison

* Update compare logic

* update blobs

* disable checking if blob has changed


Commit migrated from https://github.com/dotnet/corefx/commit/fe3678109c8897854f7c943d2a0e44a127852d54
2017-06-22 17:15:30 -07:00
Dan Moseley dc70f701c4 Disabling binary serialization fuzzying test (dotnet/corefx#21185)
Commit migrated from https://github.com/dotnet/corefx/commit/e6ae9731e6fe6dd2d5242cbbef59494f49dae7b6
2017-06-18 18:47:53 +02:00
Krzysztof Wicher c839ffc276 Add more serialization test cases and fix SqlGuid (dotnet/corefx#21137)
* add more test cases for existing types

* fix some test gaps and fix SqlGuid

* comment out UpdateBlobs


Commit migrated from https://github.com/dotnet/corefx/commit/766cc77dd6a468d23974fe3045bec0418c828bfc
2017-06-16 12:37:15 -07:00
Viktor Hofer 7bcc82a237 Enabling CookieContainer serialization by exposing PathList type and adding a type forward (dotnet/corefx#21133)
Commit migrated from https://github.com/dotnet/corefx/commit/621869abb75d3c0d9bf51ff0c2237d697fe144ac
2017-06-16 12:00:00 -07:00
Viktor Hofer da2d9f1298 Reenabling disabled tests (dotnet/corefx#21101)
Commit migrated from https://github.com/dotnet/corefx/commit/cb12db36550bc0a4c1037363bbce887f32ff323c
2017-06-16 02:01:29 +02:00
Viktor Hofer 7d3ba0ab3c Cross Serialization Cleanup (dotnet/corefx#21067)
* Remove serialization from namevalucollection types

* Update blobs


Commit migrated from https://github.com/dotnet/corefx/commit/fdc5256fb8ace294ad7e64b3f8a6d7379df67705
2017-06-14 22:44:45 -04:00
Viktor Hofer f3b55355d6 Cross framework serialization finish up (dotnet/corefx#20870)
* wip: add stubs for custom isEqual

* Updated blobs, small code refactoring, disabled CookieContainer test

* Fixed netfx471 detection

* add custom equals for graph with cycles

* fix few more comparers

* Merge

* fix few more test cases

* fix few more types, fix GetExtensionMethod to work with parameters with same type name but different generic params

* finish tests (2 comparisons are commented out: search for TODO)

* Adding TypeForward for DictionaryNode

* Updating blobs

* Update Cookie hashes, adding TypeForwards, removing unnecessary equality checks for CookieCollection

* Reenabling SortedDictionary test

* Update blobs

* make cookie.Timestamp to roundtrip correctly

* regenerate netfx and corefx blobs to account for Cookie.Timestamp change

* make regex fix the blob for ObjectWithArray

* fix ObjectWithArray netfx test failure

* Replacing Dictionary with Hashtable for desktop serialization support

* Update blobs

* Fixing a lot of TypeForwards, adding another hashtable test, other fixes

* Adding a few more TypeForwardedFrom attributes

* Updating the coreclr version, disabling CookieContainer test

* Update blobs

* Disabling CompareInfo test --> waiting for coreclr

* generate test cases

* update blobs, comment out not working cases

* fix null equality checks for new test cases and reenable them

* PR feedback addressed

* Fixed a typo...

* Updating used coreclr version, enabling compareinfo test again


Commit migrated from https://github.com/dotnet/corefx/commit/cdfb6ecf11cae3f43d35233852ef422cb12ef3d8
2017-06-15 01:18:01 +02:00
Tarek Mahmoud Sayed 8754550d62 Enable UAP Remote Execution for all tests (dotnet/corefx#21014)
This change to enable remote execution of all corefx tests in UAP. Because the remote execution code for UAP is using WinRT APIs and to avoid forcing adding UAP configuration to all test projects, we factor the remote execution code into its own test library (called TestHelper) which is cross compiled.

Commit migrated from https://github.com/dotnet/corefx/commit/eb2f543b189e8f7f9ae4c31e832ac9d3c22bb41a
2017-06-14 13:26:57 -07:00
Stephen Toub e3d4efc9ef Bring SerializationFieldInfo back to BinaryFormatter in corefx (dotnet/corefx#20938)
We initially left SerializationFieldInfo out of corefx as it wasn't necessary given previous goals around BinaryFormatter; but now it is.  I've ported the code almost as-is from desktop, with some minor style tweaks, and a few necessary changes, e.g. using FieldInfo instead of RuntimeFieldInfo, as the latter isn't accessible.  I've not done anything to minimize allocations / improve perf, etc., as that can be done in the future, and the results of all of this gets cached.

Changing this required regenerating a few of the serialization blobs in the tests.  I also added a test for a case we didn't previously cover, a [Serializable] type derived from a non-serializable type.

Commit migrated from https://github.com/dotnet/corefx/commit/82e327c0e947b4e3537d1189ce44025b8b868da1
2017-06-12 23:48:46 -04:00
Viktor Hofer 8c31646eaf Addressing previous serialization PR feedback from danmosemsft (dotnet/corefx#20807)
Commit migrated from https://github.com/dotnet/corefx/commit/432cbc26d8a657a72d3f08f91970bf865cc2ff30
2017-06-08 07:19:31 -07:00
Morgan Brown c46a97d532 More AOT serialization fixes (dotnet/corefx#20800)
* Fix byreflike test for UAPAOT

* More fixes for UAP AOT BinaryFormatter tests:
* Making Cookie serialize correctly (I'm not sure why this wasn't needed for CoreCLR)
* More rd.xml
* Avoid private reflection in the test Comparer comparison


Commit migrated from https://github.com/dotnet/corefx/commit/c1fe8a8352ba633abfad979ea2be6ade428f505b
2017-06-08 14:34:52 +02:00