json.net - Cannot build Newtonsoft.Json.Tests with Mono 4 due to inaccessible internal structs and classes -
for fedora, want build newtonsoft.json mono 4. nice run tests well. when building newtonsoft.json.tests.net40.csproj, errors this:
utilities/datetimeutilstests.cs(56,24): error cs0122: `newtonsoft.json.utilities.stringreference' inaccessible due protection level
so checking source code: https://github.com/jamesnk/newtonsoft.json/blob/master/src/newtonsoft.json.tests/utilities/datetimeutilstests.cs#l56 https://github.com/jamesnk/newtonsoft.json/blob/master/src/newtonsoft.json/utilities/stringreference.cs#l30
stringreference defined internal struct
.
according https://msdn.microsoft.com/library/7c5ka91b.aspx, "internal types or members accessible within files in same assembly"
so how ever going work? missing? work on ms.net, not on mono?
internals visible not assembly defined, friendly assemblies. friendly assemblies can read in msdn
in source code defined here , here
possible try run tests signed version of newtonsoft.json.dll , has different public key defined in source (because signed assembly own *.snk file) , reason why tests assembly not see internals in main assembly.
Comments
Post a Comment