Skip to content
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

Flaky test: Com2Interop.COM2FontConverterTests.COM2FontConverter_ConvertManagedToNative #8521

Closed
Tracked by #8607
runfoapp bot opened this issue Jan 24, 2023 · 3 comments
Closed
Tracked by #8607

Comments

@runfoapp
Copy link

runfoapp bot commented Jan 24, 2023

Runfo Tracking Issue: Flaky test: Com2Interop.COM2FontConverterTests.COM2FontConverter_ConvertManagedToNative

Build Definition Kind Run Name

Build Result Summary

Day Hit Count Week Hit Count Month Hit Count
0 0 0
@dreddy-work
Copy link
Member

Error message
Assert.Equal() Failure\r\nExpected: 20 (rounded from 20)\r\nActual: 2 (rounded from 1.5)

Stack trace
at System.Windows.Forms.Tests.ComponentModel.Com2Interop.COM2FontConverterTests.COM2FontConverter_ConvertManagedToNative() in /_/src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/ComponentModel/Com2Interop/COM2FontConverterTests.cs:line 93
at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)

@lonitra
Copy link
Member

lonitra commented Feb 27, 2023

When applying differences between the managed Font object and the native object, we use the the Font object's SizeInPoints, which seems to be dependent on DPI.

if (source.SizeInPoints != (float)target.Size)
{
target.Size = (CY)source.SizeInPoints;
targetChanged = true;
}

It may be possible running this test concurrently with others is causing issues. Perhaps this class should be in its own collection with parallelization disabled.

@ghost ghost added 🚧 work in progress Work that is current in progress and removed 🚧 work in progress Work that is current in progress labels Mar 14, 2023
@dreddy-work
Copy link
Member

closing against #8864

@ghost ghost locked as resolved and limited conversation to collaborators Apr 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants