Hi,
I am trying to write some coded UI tests to test interactions between XamRibbon and other UI parts. The buttons on our Ribbon are mostly ToggleButtonTool acting as a filter. When using UI Map builder, it only recognizes ToggleButtonTool as a Button rather than a ToggleButton so that I cannot assert "IsPressed" property. Does anyone has any clue?
Thanks!
Hello zswei,
I have been investigating into this issue and it turns out this is an internal issue in the CodedUI itself https://connect.microsoft.com/VisualStudio/feedback/details/781300/coded-ui-tests-fail-to-recognize-a-togglebutton-as-a-togglebutton-when-hosted-in-an-element-whose-peer-supports-the-expandcollapse-pattern , where the XamRibbon’s Groups actually supports the ExpandCollapse pattern (which it needs to support because ribbon groups can be collapsed). In the link there is also a sample project that reproduces this with same issue with MS only controls.
Please let me know, if you require any further clarification on the matter.
Thank you for submitting this, I have been investigating it and have been able to replicate it on my side. I am currently trying to find what is actually causing this and if it can be overcome within the current functionality.
I will keep you update on my research.