Add support for adding the view hierarchy description as an attachment#1330
Merged
Add support for adding the view hierarchy description as an attachment#1330
Conversation
…t to the test results
amorde
commented
Jul 2, 2025
| printf("%s", [self viewHierarchyDescription].UTF8String); | ||
| } | ||
|
|
||
| + (NSString *)viewHierarchyDescription { |
Contributor
Author
There was a problem hiding this comment.
almost all of the changes in this file are to update the print methods to support returning an NSString instead of printing directly via printf
amorde
commented
Jul 2, 2025
| if(traits == UIAccessibilityTraitNone) { | ||
| printf("none"); | ||
| didPrintOne = true; | ||
| [components addObject:@"none"]; |
Contributor
Author
There was a problem hiding this comment.
while here I simplified the logic a bit to get rid of the didPrintOne = true; stuff
square-tomb
approved these changes
Jul 2, 2025
Contributor
square-tomb
left a comment
There was a problem hiding this comment.
Nice. A couple possible copy/paste errors noted.
Co-authored-by: Tom Brow <106167956+square-tomb@users.noreply.github.com>
Co-authored-by: Tom Brow <106167956+square-tomb@users.noreply.github.com>
nabs-m
approved these changes
Jul 2, 2025
mjohnson12
approved these changes
Jul 2, 2025
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Adds an environment variable
KIF_ATTACHVIEWTREEONFAILUREwhich, when set toYES, will attach aView Hierarchy.txtattachment to the test results.The contents are the same as the view hierarchy description that gets printed when
KIF_PRINTVIEWTREEONFAILUREis set.