-
-
Notifications
You must be signed in to change notification settings - Fork 21
Compilation error fix in player build #33
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
Compilation error fix in player build #33
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request fixes code compilation errors in player builds by conditionally compiling test assertions and flags with UNITY_EDITOR preprocessor directives.
- Wrapped LogAssert calls with UNITY_EDITOR directives to prevent compilation errors in player builds.
- Added TODO comments indicating that a solution for player builds is needed.
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
Assets/_PackageRoot/Tests/Base/Utils/TestUtils.LoadFail.cs | Wrapped LogAssert.Expect in UNITY_EDITOR to avoid compilation errors in player builds. |
Assets/_PackageRoot/Tests/Base/Utils/TestUtils.cs | Wrapped LogAssert.ignoreFailingMessages assignments in UNITY_EDITOR blocks to fix player build compilation errors. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a compilation error in player builds by updating references to UnityEngine.TestTools.LogAssert across several test files. The changes ensure that test builds using player runtimes no longer fail due to missing using directives for LogAssert.
- Removed the generic using directive for UnityEngine.TestTools from test files where it caused build issues.
- Replaced unqualified LogAssert calls with fully qualified UnityEngine.TestTools.LogAssert calls in TestUtils.LoadFail.cs and TestUtils.cs.
- Adjusted the ordering of using directives in TestConcurrency.cs for consistency.
Reviewed Changes
Copilot reviewed 3 out of 7 changed files in this pull request and generated no comments.
File | Description |
---|---|
Assets/_PackageRoot/Tests/Base/Utils/TestUtils.LoadFail.cs | Updated LogAssert usage to resolve compilation error in player build. |
Assets/_PackageRoot/Tests/Runtime/TestConcurrency.cs | Moved UnityEngine.TestTools directive to improve consistency. |
Assets/_PackageRoot/Tests/Base/Utils/TestUtils.cs | Updated LogAssert.ignoreFailingMessages usage with full namespace for player build compatibility. |
Files not reviewed (4)
- Assets/_PackageRoot/Tests/Base/Extensions.Unity.ImageLoader.Tests.asmdef: Language not supported
- Assets/_PackageRoot/Tests/Editor/Extensions.Unity.ImageLoader.Tests.Editor.asmdef: Language not supported
- Assets/_PackageRoot/Tests/Runtime/Extensions.Unity.ImageLoader.Tests.Runtime.asmdef: Language not supported
- Assets/_PackageRoot/package.json: Language not supported
No description provided.