Commit 663b52a
committed
Make sure culture info is persisted across methods executed from classes with UseCulture attribute
When we change the current thread's culture, that change is lost
when an async method is called. So Microsoft guys have introduced
the CultureInfo.DefaultThreadCurrentCulture property in .NET 4.5.
See https://stackoverflow.com/a/30664385/1396155
According to this SO answer, we do not have to use this property
in .NET 4.6 because async methods seem to get the same culture info
the caller method has. So if someday the test project's target
framework is updated, feel free to revert this commit.1 parent 7cf7332 commit 663b52a
1 file changed
Lines changed: 12 additions & 0 deletions
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
36 | 40 | | |
37 | 41 | | |
38 | 42 | | |
| |||
85 | 89 | | |
86 | 90 | | |
87 | 91 | | |
| 92 | + | |
| 93 | + | |
88 | 94 | | |
89 | 95 | | |
90 | 96 | | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
91 | 100 | | |
92 | 101 | | |
93 | 102 | | |
| |||
99 | 108 | | |
100 | 109 | | |
101 | 110 | | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
102 | 114 | | |
103 | 115 | | |
104 | 116 | | |
0 commit comments