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

Add preferredScreenCaptureFormat to XCScheme.TestAcion #792

Merged

Conversation

tatagrigory
Copy link
Contributor

@tatagrigory tatagrigory commented Sep 1, 2023

Short description 📝

XCTest now supports automatic screen recordings in addition to screenshots. Screen recordings allow for a fine-grained view of what happened during a test run, which can be meaningful to investigate UI test failures. Screen recordings are enabled by default (in favor of screenshots). They can be disabled in the test plan or the scheme’s Test action options.

  • Available options are:
    • Screenshots - prior to Xcode 15 is was the only available format
    • Screen Recording - new feature of Xcode 15
  • It can be configured in the scheme test action options
    New option screenshot Screenshot 2023-09-01 at 17 21 35

Solution 📦

  • To support this new option it was added to XCScheme.TestAcion

Implementation 👩‍💻👨‍💻

  • Add new enum ScreenCaptureFormat with supported capture formats
  • Add new optional property of the ScreenCaptureFormat type to XCScheme.TestAcion
  • Update tests

Notes 📝

  • The new option is ignored by Xcode 14.x and prior
  • Screen Recording is the default format. As such preferredScreenCaptureFormat is omitted in xcscheme when Screen Recording is selected.

@netlify
Copy link

netlify bot commented Sep 1, 2023

Deploy Preview for xcodeproj ready!

Name Link
🔨 Latest commit 3005571
🔍 Latest deploy log https://app.netlify.com/sites/xcodeproj/deploys/64f211e6a0f96c0008167ade
😎 Deploy Preview https://deploy-preview-792--xcodeproj.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Collaborator

@kwridan kwridan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @tatagrigory

@kwridan
Copy link
Collaborator

kwridan commented Sep 4, 2023

@all-contributors add @tatagrigory for code

@kwridan kwridan marked this pull request as ready for review September 4, 2023 07:01
@allcontributors
Copy link
Contributor

@kwridan

I've put up a pull request to add @tatagrigory! 🎉

@pepicrft pepicrft merged commit 3797181 into tuist:main Sep 8, 2023
10 checks passed
@tatagrigory tatagrigory deleted the tg/add-preferredScreenCaptureFormat branch September 13, 2023 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants