-
-
Notifications
You must be signed in to change notification settings - Fork 261
feat: Architectural Refactor of Dependency Injection and Query System #412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
YBTopaz8
wants to merge
17
commits into
master
Choose a base branch
from
v5.1.0
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 14 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
4017b43
Add CurrentUser property to IParseCurrentUserController
YBTopaz8 527a337
Refactor ParseFieldOperations and enhance Decode method
YBTopaz8 1048990
Refactor ParseDataDecoder and update ParseObjectCoder comments
YBTopaz8 e93f3ef
Add Or method and implement GetHashCode in ParseQuery
YBTopaz8 7abb50a
Refactor service hub structure and user authentication
YBTopaz8 575c2ae
Refactor IParseDataDecoder.Decode method signature
YBTopaz8 150505f
Refactor service access to use `this.Services` property
YBTopaz8 d85670a
Refactor ConvertToJSON method in IJsonConvertible classes
YBTopaz8 89822ca
Refactor Decode method signatures and update tests
YBTopaz8 667d277
Enhance tests and improve exception handling
YBTopaz8 f7881be
Add error code and new ParseErrorPayload class and Enhance ParseComma…
YBTopaz8 b261de8
Refactor ParseQueryControllerTests and add new tests
YBTopaz8 66b7b70
Add unit tests for decoding Parse field operations
YBTopaz8 a083849
Refactor and enhance unit tests across multiple files
YBTopaz8 1023430
Removed commented code
YBTopaz8 f255c95
Refactor HTTP response code handling
YBTopaz8 b342554
Fix enum value ordering.
YBTopaz8 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Reflection; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
using Parse.Infrastructure.Control; | ||
using Parse.Infrastructure.Utilities; | ||
|
||
namespace Parse.Tests; | ||
|
||
|
||
[TestClass] | ||
public class AttributeTests | ||
{ | ||
[TestMethod] | ||
[Description("Tests that PreserveAttribute can set its boolean properties correctly.")] | ||
public void PreserveAttribute_SetPropertiesCorrectly() | ||
{ | ||
var preserve = new PreserveAttribute { AllMembers = true, Conditional = true }; | ||
Assert.IsTrue(preserve.AllMembers); | ||
Assert.IsTrue(preserve.Conditional); | ||
preserve.AllMembers = false; | ||
preserve.Conditional = false; | ||
Assert.IsFalse(preserve.AllMembers); | ||
Assert.IsFalse(preserve.Conditional); | ||
} | ||
[TestMethod] | ||
[Description("Test LinkerSafe attribute and ensures there is not exceptions on constructor.")] | ||
public void LinkerSafeAttribute_CanBeCreatedWithoutErrors() | ||
{ | ||
var safe = new LinkerSafeAttribute(); | ||
Assert.IsNotNull(safe); | ||
} | ||
[TestMethod] | ||
[Description("Tests that the PreserveWrapperTypes class has the Preserve attribute")] | ||
public void PreserveWrapperTypes_HasPreserveAttribute() | ||
{ | ||
var attribute = typeof(PreserveWrapperTypes).GetTypeInfo().GetCustomAttribute<PreserveAttribute>(true); | ||
Assert.IsNotNull(attribute); | ||
Assert.IsTrue(attribute.AllMembers); | ||
} | ||
|
||
[TestMethod] | ||
[Description("Test that types exists in the AOTPreservations List with correct types.")] | ||
public void PreserveWrapperTypes_HasCorrectlyAOTTypesRegistered()// 1 | ||
{ | ||
var property = typeof(PreserveWrapperTypes).GetTypeInfo().GetDeclaredProperty("AOTPreservations"); | ||
var list = property.GetValue(null) as List<object>; | ||
|
||
Assert.IsNotNull(list); | ||
Assert.IsTrue(list.Any(p => p.Equals(typeof(FlexibleListWrapper<object, object>)))); | ||
Assert.IsTrue(list.Any(p => p.Equals(typeof(FlexibleListWrapper<float, float>)))); | ||
|
||
Assert.IsTrue(list.Any(p => p.Equals(typeof(FlexibleDictionaryWrapper<object, object>)))); | ||
Assert.IsTrue(list.Any(p => p.Equals(typeof(FlexibleDictionaryWrapper<double, float>)))); | ||
} | ||
|
||
|
||
} |
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.