Commit Graph

85 Commits

Author SHA1 Message Date
Maxim Krouk 434dfeca2e Add excludeFromProject option for local packages (#1512) 2025-02-17 16:08:54 +11:00
Ernesto Cambuston 45151c2882 Allow changing macro expansions on test actions. (#1468)
* Allow to override test macroExpansions

* update doc

* style

* Address feedback from PR

* fix build

* add toJSONValue encoding
2024-07-10 12:19:30 +10:00
Ernesto Cambuston f8842228c5 Test action macroExpansion allows unavailable buildable reference. (#1471)
* fix buildable ref

* fix test

* add test
2024-07-03 21:41:03 +10:00
Balazs Perlaki-Horvath 1645d419ce Add shell to ExecuteAction (#1430)
* Add shell to ExecuteAction

* Update to 2.38.1

* Add shell argument to jsons
2024-04-07 22:38:04 +10:00
Antoine Piellard a10bd4baa0 Add support to disable "Thread Performance Checker" (#1380)
* Add disableThreadPerformanceChecker scheme option

* Update changelog
2023-08-08 08:50:13 +10:00
LouisLWang f33d600d50 adding support for enableGPUValidationMode (#1294)
* adding support for enableGPUValidationMode

* encode enableGPUValidationMode in Scheme.Run.toJSONValue()

* ci: commit fixtures changes

* docs: Add changelog for enableGPUValidationMode

update Doc ProjectSpec.md

* docs: update ProjectSpec.md for enableGPUValidationMode default value

---------

Co-authored-by: wanglulu <louiswang@lilith.com>
2023-07-13 20:58:32 +10:00
Wendy Liga 43e40a9efc Added support for scheme management (#1142)
* wip

* Added scheme management metadata properties to TargetScheme

* wip

* Added Scheme.Management for metadata

* use sharedDefault

* move generateSchemeManagement to SchemeGenerator

* revert

* update changelog

* update docs

* update test case

* remove

* remove unused file

* revert

* changed on fixtures project

* Updated ProjectSpec docs index

* User Scheme.Management also for TargetSchemes, use XCUserData

* Changelog

* Switch XcodeProj back tuist/XcodeProj - 8.9.0

* Reindent TOC Docs/ProjectSpec.md

* Revert swift tools version

---------

Co-authored-by: Tieme van Veen <tiemevanveen@hotmail.com>
2023-02-24 09:49:57 +11:00
Craig Siemens ed5ec74668 Added scheme generation for aggregate targets (#1250)
* Updated SchemeGenerator to generate schemes for all projectTargets.

* Added changelog entry
2022-09-29 14:08:37 +10:00
Bobby Sudekum 6f331720c9 Add enableGPUFrameCaptureMode to Scheme (#1251) 2022-09-09 18:43:39 +10:00
Steven Sheldon e9295f1ff3 Fix profile action to not run frameworks (#1245)
* Fix profile action to not run frameworks

* Add PR number to changelog

* Update CHANGELOG.md

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2022-08-11 22:45:06 +10:00
Yonas Kolb e35f7df14d Add Test Plans (#716)
* upgrade scheme and project versions

* parse test plans

* remove xctestplan from resources

* generate test plan references in schemes

* add test plan to fixture

* non-mutable way of creating [XCScheme.TestPlanReference]

* update fixture version

* Add documentation

* Add default test plan option

# Conflicts:
#	Sources/ProjectSpec/Scheme.swift
#	Tests/Fixtures/paths_test/included_paths_test.yml
#	Tests/ProjectSpecTests/SpecLoadingTests.swift

* Add test plan validation

# Conflicts:
#	Tests/ProjectSpecTests/ProjectSpecTests.swift

* Check for multiple default test plans

* set first plan as default default plan

* small tweaks

* fix test plan path properties

* add test plants to target scheme

* docs

* fix fixture test plan path

* update changelog

* added ability to disable test plan path validation

Co-authored-by: Ota Mares <ota@rebuy.com>
2022-05-10 13:27:31 +10:00
John Connolly be0c3c3926 Added ability to use custom location for local Swift packages (#1175)
* Added xcodePath functionality

* Added xcodePath functionality

* Renamed Xcode path to group

* Updated change log and added fixture tests
2022-03-25 11:26:06 +11:00
freddi(Yuki Aki) 245f17117a Support test target for local Swift Package (#1169)
* support local Swift Package test case into test scheme

* update test

* add test

* update CHABGELOG.md

* Update CHANGELOG.md

* revert resolved package test

* Update Sources/XcodeGenKit/SchemeGenerator.swift

Co-authored-by: Kohki Miki <giginet.net@gmail.com>

* make TargetReference convert from new JSON format

* add .package for location of target reference

* receive target reference format at target of scheme

* update test

* update XcodeProj

* add test and fix small bugs

* update docs

* support multiple style of coverageTargets

* add edge case of parsing test targets

* fix docs

* Update Docs/ProjectSpec.md

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* create TestableTargetReference for not making API complex

* fix code format

* fix parameter name to Testable Target Reference

* support directly writing key of Testable Target Reference

* fix compile error in build

Co-authored-by: Kohki Miki <giginet.net@gmail.com>
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2022-03-20 14:27:29 +11:00
Gabriel Lanata 3b5ca91b76 Add coverage targets for target schemes (#1189)
* Changes

* Tests and docs

* Update fixtures

* Update CHANGELOG.md

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2022-03-17 15:56:03 +11:00
Kristopher Jackson c62277f150 Added location option to test target (#1153)
* Added location option to test target

* Updated XcodeProj

* Updated packages

* Removed extra toJSONValue()

* Update Docs/ProjectSpec.md

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* Update Sources/ProjectSpec/Scheme.swift

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* Update Sources/ProjectSpec/Scheme.swift

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* Removed optional location

* Renamed SimulateLocation to Location

* Removed Location struct and just pass location string directly

* Added tests for location with a test target

* Added example of location inside test target to project.yml

* Removed extra test target and add location to existing target

* Updated App_Scheme.xcscheme

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2022-01-07 11:09:58 +11:00
Dalton Claybrook 66b1db4b5c Add support for specifying the UI testing screenshot behavior in a scheme test action (#942)
* Support for specifying UI testing snapshot behavior in scheme test action

* Add tests for new screenshot scheme options

* Update changelog

* Add new fields to Scheme.Test json encoding

* Only save values to JSON if they aren't the defaults

* Using new defaults constants
2021-06-27 22:25:26 +10:00
freddi(Yuki Aki) 4233cc8578 Support runPostActionsOnFailure on build scheme (#1075)
* supports runPostActionsOnFailure on build scheme

* updates test for runPostActionsOnFailure

update runPostActionsOnFailure tests

* update Docs for runPostActionsOnFailure

* update change log

* Update CHANGELOG.md

* Update CHANGELOG.md
2021-05-06 12:54:33 +10:00
Stefano Mondino dfe7f28bcb Scheme config variants wrong assignment for similar config names (#976)
* Failing test for #975

* fixes #975

* chore: refactor to properly select a config from a collection with specific variant and config type
chore: updated changelog

* fix: lowercase compare on config variant names

* fix CI

* fix missing scheme for CI

* fix schemes for CI

* Update CHANGELOG.md

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* Update Sources/ProjectSpec/Config.swift

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>

* - fix compilation issue
- duplicated test for config variant name (uppercase/lowercase)

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2021-05-01 15:50:39 +10:00
Artem Semavin 0ac7a5f8c6 Added support for SelectedTests in schemes Test configuration. (#913)
* added support for selectedTests in test shemes

* added PR description to changelog

* CHANGELOG fix

* use presence of selectedTests for useTestSelectionWhitelist

Co-authored-by: Artem Semavin <Artem Semavin>
Co-authored-by: yonaskolb <yonaskolb@gmail.com>
2021-04-08 23:01:28 +10:00
André 209afcc898 Allowing override LastUpgradeCheck and LastUpgradeVersion (#1013)
* Allowing the property LastUpgradeCheck and LastUpgradeVersion to be overrided

* Updating changelod and project spec

* Updating changelog

Co-authored-by: André Lucas Ota <andrel.ota@PPM-SPO-6835.local>
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2021-04-08 22:20:10 +10:00
Dale ff64a4a1cb Set error message for missing build targets in scheme (#1040)
* Set error message for missing build targets in scheme

The current behavior means it just crashes due to trying to force unwrap
a nil optional.

Note: A build target shouldn't really be needed, but this is just a
quick fix to get things moving again.

* Update changelog
2021-04-01 08:57:42 +11:00
freddi(Yuki Aki) cf88681749 Support macroExpansion on run scheme (#1036)
* allow to specify macroExpansion on schemes

* fix json parsing on macroExpansion

* set macroExpansion only launch scheme

* add test for macroExpansion

* add macroExpansion description

* add macroExpansion to Change Log

* Update CHANGELOG.md

* add App_Extension scheme for macroExpansion

* change example of macroExpansion in Fixtures project

* fix to keep back to keep back compatibility as possible

* Apply suggestions from code review

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2021-03-21 20:02:01 +11:00
freddi(Yuki Aki) f550d01678 Support askForAppToLaunch on profile scheme (#1035)
* add askForAppToLaunch to profile scheme

* add test

* add description for askForAppToLaunch

* add Change Log for askForAppToLaunch

* Update Docs/ProjectSpec.md
2021-03-17 18:10:04 +11:00
Joseph Colicchio ae186edb68 Bugfix/SimulateLocation Fix (#973)
* Preemptively fix compilation for latest XcodeProj

* Add StoreKitConfiguration to scheme and generator

* Add scheme generator test

* Fix and add tests

* Support StoreKitConfiguration in TargetScheme

* Set default type of `storekit` to `.none`

* Upgrade XcodeProj to 7.15.0

* Create struct for StoreKitConfiguration

* Update tests

* Add storekit configuration to test project

* Update changelog

* Update project spec

* Fix xcodeprojs

* Fix projects

* Capitalize String

* Update CHANGELOG.md

Co-authored-by: Gemma Barlow <gemmakbarlow@gmail.com>

* Refactor StoreKitConfiguration init from json

* Change `forWorkspace` to `pathPrefix` and add tests

* Replace StoreKitConfiguration struct with string + option

* Fix tests

* Update project spec

* Fixup changelog

* Add `See Options` to `storeKitConfiguration` in project spec

* Make `simulateLocation` respect `schemePathPrefix`

* Update docs

Co-authored-by: Gemma Barlow <gemmakbarlow@gmail.com>
2021-02-16 09:35:47 +11:00
Joseph Colicchio 50aedc4511 Feature/Store Kit Configuration (#964)
* Preemptively fix compilation for latest XcodeProj

* Add StoreKitConfiguration to scheme and generator

* Add scheme generator test

* Fix and add tests

* Support StoreKitConfiguration in TargetScheme

* Set default type of `storekit` to `.none`

* Upgrade XcodeProj to 7.15.0

* Create struct for StoreKitConfiguration

* Update tests

* Add storekit configuration to test project

* Update changelog

* Update project spec

* Fix xcodeprojs

* Fix projects

* Capitalize String

* Update CHANGELOG.md

Co-authored-by: Gemma Barlow <gemmakbarlow@gmail.com>

* Refactor StoreKitConfiguration init from json

* Change `forWorkspace` to `pathPrefix` and add tests

* Replace StoreKitConfiguration struct with string + option

* Fix tests

* Update project spec

* Fixup changelog

* Add `See Options` to `storeKitConfiguration` in project spec

Co-authored-by: Gemma Barlow <gemmakbarlow@gmail.com>
2021-02-15 11:58:16 +11:00
Elliott Williams 2601d39792 Support Linux by upgrading XcodeProj and Spectre (#988)
* Bump XcodeProj and Spectre

* Add LinuxMain.swift

* Linux test fixups

* Add CI job for ubuntu-latest

* Use URLs in glob logic to avoid Linux/Mac foundation inconsistencies

* fatalError when --enable-test-discovery is not used

* Update fixtures

They changed because of a bugfix in XcodeProj: https://github.com/tuist/XcodeProj/pull/563

* Update CHANGELOG.md
2020-11-24 11:28:41 +11:00
Cody Vandermyn 43177dec49 Select the first runnable target (#957)
* Select the first runnable target, if there is one

Instead of just selecting the first target as the scheme target, instead search for and select the first runnable target. If there are no runnables found, then select the first target.

* update docs
2020-09-29 16:44:53 +10:00
Brentley Jones 5ac96741bc Improved Application Extension scheme generation (#932)
* Default extensions to launchAutomaticallySubstyle "2"

* Don't use debugger launcher with extensions

Xcode schemes don't use the LLDB launcher, even when debugging is enabled.

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2020-09-06 15:40:32 +10:00
Bartosz Polaczyk 1d2a28490f Add custom lldinit for a scheme (#929)
* Add customLLDBInit

* Add changelog info to a valid bucket

* Update PR number

* Add fixture tests

Co-authored-by: Bartosz Polaczyk <bartoszp@spotify.com>
2020-08-12 16:13:47 +10:00
Cody Vandermyn 727a648623 Add ability to skip the entire test target (#916)
* add ability to skip the entire test target

* when skipped is true, add it to the toJSONValue dictionary

* Add changelog entry
2020-08-05 20:05:23 +10:00
Muhammad Muizzsuddin d68900e313 Fix app extension scheme generation (#899)
* Fix XCScheme generation for Extension

* Use schemeTarget
2020-07-26 22:17:32 +10:00
Yonas Kolb 7da953a488 swift format 2020-06-17 18:12:34 +10:00
Yonas Kolb 179eec45d9 rename executableName to executable 2020-06-17 17:23:17 +10:00
Joeri Djojosoeparto 7ec2f7f8e3 Feature: Ability to set executable to Ask to Launch (#871) 2020-05-29 07:53:48 -05:00
Igor Ranieri Elland 463db0616d Added ability to name executable target in schemes Run configuration. (#869) 2020-05-28 07:50:52 -05:00
Igor Ranieri Elland 92aaebb9d5 Added ability to name the executable target in schemes. (#866)
```
schemes:
  MyScheme:
    build:
      executable: MyExecutable
      targets:
      ...
```

Co-authored-by: Igor Ranieri Elland <igor.ranieri@de.bosch.com>
2020-05-20 08:05:03 -05:00
Brentley Jones 0319116f94 Prevent tests from being set as launch actions (#835)
When a scheme only contains a test target, and you want it to build when "Building for Run", you don't want the test target to be set as the launch action. This fixes that.

Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
2020-04-23 08:00:44 -05:00
Brentley Jones e44dcd3948 Set scheme actions to build step for TargetScheme (#823)
Adjusts the preActions and postActions of a TargetScheme to only be applied applied to the `build` step.
2020-04-13 23:30:46 +10:00
Sebastian Celis 0328fa03e7 Add improved support for simple iOS sticker packs (#824)
* Allow messages applications to skip the compile sources phase

By default, simple iOS sticker packs created in Xcode do not include
a compile sources phase. This change will allow messages applications
with an empty list of sources to skip that phase entirely.

* Add support for launchAutomaticallySubstyle in run schemes

This is especially important for simple iOS sticker packs that require
this run scheme setting to be set to 2 in order to run the scheme
properly.
2020-04-06 13:37:37 -05:00
Dalton Claybrook 039f6c31e7 Use remote-runnable launch actions for Apple Watch schemes (#798)
* Add support for using remote runnables with an Apple Watch scheme
2020-03-26 08:14:46 -05:00
Evan Coleman 0d714bb47e add buildImplicitDependencies to TargetScheme 2020-03-20 13:23:50 -04:00
ionutivan 5487e3ce18 add property stopOnEveryMainThreadCheckerIssue to the scheme, target scheme and generator 2020-03-04 17:21:18 +01:00
Bas van Kuijck f544dd36e6 Added a simulateLocation option in scheme specs (#756)
* Added a simulateLocation option in scheme specs

* Updated fixtures for simulateLocation

* Use fileGroups instead of sources
2020-01-23 09:12:06 -06:00
John Flanagan c52ed49a29 Prefer default Debug and Release configs 2020-01-14 21:40:12 -06:00
Kamil Pyć 9bf657cb1d Use full path for XcodeProj
This solves issue with relative project path.
2020-01-07 14:20:16 +01:00
Franz Busch bedbfef9cd Add support for language and region for targets 2019-12-04 09:35:56 +01:00
Ken Tominaga fd05b9ba08 Use Xcode.IDEFoundation.Launcher.PosixSpawn for TestAction when debugEnabled: false 2019-11-23 01:46:57 +09:00
yonaskolb 0e4e08bfc4 run swift format for Swift 5.1 2019-11-10 11:56:23 +11:00
Yuta Saito 3a810d1499 Add missing onlyGenerateCoverageForSpecifiedTargets which enables specific target coverage 2019-10-30 15:17:08 +09:00
yonaskolb d0d509c1a5 swiftformat 2019-10-27 22:37:41 +11:00