Use Task.Run instead of BeginInvoke in tests

Description

Calling BeginInvoke() on delegates is obsolete and throws an exception in .NET Core:

System.PlatformNotSupportedException : Operation is not supported on this platform.

The same thing can be done with Task.Run().

This is required for https://nhibernate.jira.com/browse/NH-3807#icft=NH-3807

Environment

None

Activity

Show:
Alex Zaytsev
updated the Issue Type
September 20, 2017 at 3:26 AM
Task
Improvement
Alex Zaytsev
updated the Summary
September 20, 2017 at 3:02 AM
Use Task.Run instead of BeginInvoke.
Use Task.Run instead of BeginInvoke in tests
Frédéric Delaporte
changed the Assignee
July 15, 2017 at 7:39 PM
Unassigned
Frédéric Delaporte
Frédéric Delaporte
changed the Status
July 15, 2017 at 7:39 PM
Open
Resolved
Frédéric Delaporte
updated the Resolution
July 15, 2017 at 7:39 PM
None
Fixed
Frédéric Delaporte
updated the Fix versions
July 15, 2017 at 7:39 PM
None
5.0.0
Nathan Brown
created the Work item
July 14, 2017 at 2:46 AM
Fixed

Details

Assignee

Reporter

Components

Fix versions

Affects versions

Priority

Who's Looking?

Open Who's Looking?
Created July 14, 2017 at 2:46 AM
Updated September 20, 2017 at 3:26 AM
Resolved July 15, 2017 at 7:39 PM
Who's Looking?