MarathonLabs / marathon

Cross-platform test runner
https://docs.marathonlabs.io
GNU General Public License v2.0
584 stars 122 forks source link

feat(ios): add xctest parser #848

Closed Malinskiy closed 1 year ago

Malinskiy commented 1 year ago

The iOS test platform has always been problematic to parallelise since there is no way to get a list of tests for execution. Although Swift supports parsing via --list-tests, this doesn't work for native iOS targets and not all the tests are written using Swift (some test frameworks merele pretend they're xctest-based)

This change adds xctest parser with support for any xctest-compliant tests including runtime-generated ones. This potentially removes the use-case for testClassRegex since all tests will be reported directly and there is no filtering needed like the filtering for potentially large symbol table of the binary using nm.

Note: xctest parser is optional and contains code under EULA

codecov[bot] commented 1 year ago

Codecov Report

Merging #848 (228f594) into develop (3f3959e) will increase coverage by 0.00%. The diff coverage is 66.66%.

:exclamation: Current head 228f594 differs from pull request most recent head b2b5686. Consider uploading reports for the commit b2b5686 to get more accurate results

@@            Coverage Diff             @@
##             develop     #848   +/-   ##
==========================================
  Coverage      59.56%   59.56%           
  Complexity       799      799           
==========================================
  Files            213      214    +1     
  Lines           4397     4400    +3     
  Branches         692      692           
==========================================
+ Hits            2619     2621    +2     
- Misses          1452     1453    +1     
  Partials         326      326           
Files Coverage Δ
...skiy/marathon/config/vendor/VendorConfiguration.kt 43.87% <100.00%> (+0.57%) :arrow_up:
...athon/config/vendor/ios/TestParserConfiguration.kt 50.00% <50.00%> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

Vacxe commented 1 year ago

Great stuff mate