[Feature]: Visual Difference Assert
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- csharp
- Domain
- computer-vision, testing-qa
Research direction
Start by reviewing the Power Fx namespace and the proposed Preview.ImageCompare entry point described in the issue. Clarify how controls or locators, reference images, comparison types, filters, and percentage tolerance should be represented. Done means the feature supports the listed comparison modes and produces reliable pass/fail results for visual multi-model tests.
Written by the indexing model from the issue text.
Description
Is your feature request related to a problem? Please describe.
Currently, Test Engine lacks the capability to verify visual design elements of a solution comprehensively. While it is possible to test individual properties, there is a significant need for a more efficient method that allows for visual multi-model tests. This limitation hinders the ability to ensure that the visual aspects of the application meet the desired standards and expectations.
Describe the solution you'd like
Propose the introduction of a Visual Image Compare feature in the Power Apps Test Engine. This feature should include the following capabilities:
-
Control Name or Locator: The ability to use a control name or locator to find the specific element that needs to be tested. This will streamline the process of identifying and targeting the visual elements within the application.
-
Reference Image: The option to specify a reference image against which the visual elements can be compared. This will serve as a baseline for the visual comparison, ensuring consistency and accuracy in the visual design.
-
Comparison Types: The feature should support various comparison types, including Pixel, Edge Detection, Color, and Structure. This flexibility will allow for comprehensive visual testing, catering to different aspects of the visual design.
-
Tolerance for Difference: The ability to set a tolerance for differences as a percentage. This will provide a margin for acceptable variations, ensuring that minor discrepancies do not result in false negatives.
Example Usage
Here is an example of how the Visual Image Compare feature could be used within the Power Fx namespace:
Preview.ImageCompare(Tab1, "reference.png", [{Compare: "Edge"}, {Compare: "Color"}], 10);
In this example, the ImageCompare function is used to compare the visual elements of Tab1 against a reference image named "reference.png". The comparison types specified are Edge Detection and Color, with a tolerance of 10%.
Describe alternatives you've considered
No response
Additional context?
To provide a clearer understanding of the proposed feature, I have included a screenshot of the current visual design elements and a reference image for comparison. Additionally, I have attached a document outlining the detailed requirements and expected outcomes of the Visual Image Compare feature.
Related to [Feature]: Sample of Testing the Copilot Studio Kit
For example theming of chat control
Filters
To help deal with differences and false positives consider the following
Edge Detection with Polygon matching modes
Blur
Colormap
- Dominant language
- C#
- Stars
- 150
- Forks
- 55
- Avg merge
- 5d 23h
- Merged PRs (30d)
- 4
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/PowerApps-TestEngine
-
new
Difficulty 1/5 Under an hour Newbie friendliness 68/100
-
new
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
new
Difficulty 4/5 3-5 days Newbie friendliness 48/100
-
question
Difficulty 5/5 Over a week Newbie friendliness 20/100
All issues in microsoft/PowerApps-TestEngine
Similar issues
-
untriaged
Difficulty 1/5 Under an hour Newbie friendliness 88/100
dotnet/dotnet-api-docs#13095 ·
-
area-deployment area-integrations triage:bot-seen
Difficulty 2/5 Half a day Newbie friendliness 86/100
-
type/automation type/tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 90/100
newrelic/newrelic-dotnet-agent#3850 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
LuckyPennySoftware/AutoMapper#4660 ·