Move interop tests to the public interface test project #1767
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Most of those interop tests illustrate how Jint can interact with objects from popular libraries such as
Newtonsoft.Json
,System.Text.Json
and dynamic objects such asExpandoObject
.Because this can be a valuable reference for Jint users, they should not depend on any internals (which would be off limits for callers.) See #1766 for my endeavor on (successfully) integrating STJ.
This pretty much only moves the files over to the other project and updates the one location where internal code was used. Other tests like Newtonsoft and Dynamic didn't really use any internals, so it was just the namespace update there.
Initially, I moved over all tests that began with
InteropTests
and quickly realized how most of them don't really mean interop in the sense of someone external trying to interface with it. At least I got stopped by variousinternal
methods onObjectWrapper
,ObjectInstance
etc. that I simply cannot justify changing just to move the tests.Let me know if theres more (or possibly also less) you want included with this PR.