diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/examples/ios_app/test/fixtures/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/examples/ios_app/test/fixtures/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..33267beedf --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme new file mode 100644 index 0000000000..b2c68d7d0b --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme new file mode 100644 index 0000000000..1484725b4e --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..e163eb8164 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..b6dc57f48d --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..a4a3628d0b --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme new file mode 100644 index 0000000000..d6b3fdcab5 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme new file mode 100644 index 0000000000..fc405562be --- /dev/null +++ b/examples/ios_app/test/fixtures/bwb.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/examples/ios_app/test/fixtures/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/examples/ios_app/test/fixtures/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..b97a85d6b2 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme new file mode 100644 index 0000000000..2a73de45c4 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/CoreUtilsObjC.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme new file mode 100644 index 0000000000..be90270b35 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..8f4e101590 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleObjcTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleResources.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleResources.xcscheme new file mode 100644 index 0000000000..ac07055a2a --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleResources.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..e403352c0e --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..51d0499178 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExternalResources.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExternalResources.xcscheme new file mode 100644 index 0000000000..5e9a19a160 --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/ExternalResources.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme new file mode 100644 index 0000000000..7374129c1c --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/TestingUtils.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme new file mode 100644 index 0000000000..5a52da032e --- /dev/null +++ b/examples/ios_app/test/fixtures/bwx.xcodeproj/xcshareddata/xcschemes/Utils.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/cc/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/cc/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/cc/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme new file mode 100644 index 0000000000..72c74354db --- /dev/null +++ b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..e0d9f5c756 --- /dev/null +++ b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme new file mode 100644 index 0000000000..0eea98d4b6 --- /dev/null +++ b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme new file mode 100644 index 0000000000..a78d46e8b9 --- /dev/null +++ b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme new file mode 100644 index 0000000000..87f8ce010a --- /dev/null +++ b/test/fixtures/cc/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/cc/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/cc/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/cc/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme new file mode 100644 index 0000000000..7d59a826f3 --- /dev/null +++ b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/@examples_cc_external___lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..7926cf7a30 --- /dev/null +++ b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme new file mode 100644 index 0000000000..12ad3c96ca --- /dev/null +++ b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib2_lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme new file mode 100644 index 0000000000..91a3b16d40 --- /dev/null +++ b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/__examples_cc_lib_lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme new file mode 100644 index 0000000000..e5d65463f2 --- /dev/null +++ b/test/fixtures/cc/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/command_line/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/command_line/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/command_line/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..fe4dce0b79 --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..64c8009536 --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme new file mode 100644 index 0000000000..a18dfa6bb8 --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme new file mode 100644 index 0000000000..dc3fc51a0a --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme new file mode 100644 index 0000000000..899b7e737d --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme new file mode 100644 index 0000000000..4982605242 --- /dev/null +++ b/test/fixtures/command_line/bwb.xcodeproj/xcshareddata/xcschemes/tool.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/command_line/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/command_line/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/command_line/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..7db32d05e5 --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..61f12668f0 --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/LibSwiftTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme new file mode 100644 index 0000000000..bc2353708e --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_impl.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme new file mode 100644 index 0000000000..1d9e83bf59 --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/lib_swift.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme new file mode 100644 index 0000000000..b6e23f98a7 --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/private_lib.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme new file mode 100644 index 0000000000..2ab9c8f4d4 --- /dev/null +++ b/test/fixtures/command_line/bwx.xcodeproj/xcshareddata/xcschemes/tool.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/project.pbxproj b/test/fixtures/generator/bwb.xcodeproj/project.pbxproj index e50610890a..7db6d5a242 100644 --- a/test/fixtures/generator/bwb.xcodeproj/project.pbxproj +++ b/test/fixtures/generator/bwb.xcodeproj/project.pbxproj @@ -162,6 +162,7 @@ A017A60C1F5B32E3FA3AC00A /* OrderedSet+CustomStringConvertible.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6E464E0F5C4A2F0ED8DBA80 /* OrderedSet+CustomStringConvertible.swift */; }; A222D10EC921D5DAB1ADFDD8 /* Errors.swift in Sources */ = {isa = PBXBuildFile; fileRef = 737B837AF4D301FD49E5E8DC /* Errors.swift */; }; A30CF32F21CDF7FE5B477341 /* PBXTargets+ExtensionsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB622F4E8EA478F6C3D642F6 /* PBXTargets+ExtensionsTests.swift */; }; + A32E8CBF5EF43A7EA58020DA /* CreateXCSchemesTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = A41C1A5C575F9777BBECCB89 /* CreateXCSchemesTests.swift */; }; A34F10BEBBC9CABA7EFE3D62 /* OrderedSet+Partial SetAlgebra+Operations.swift in Sources */ = {isa = PBXBuildFile; fileRef = C8FF7F282D79BCC8C890152C /* OrderedSet+Partial SetAlgebra+Operations.swift */; }; A4A23349B22F60B10EDF6D9A /* Diff.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74842CED67D00EEEC35928F3 /* Diff.swift */; }; A66786EB13D7E2639036F3BF /* Generator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 57369B9A38B6DCB2216526AE /* Generator.swift */; }; @@ -545,6 +546,7 @@ A20E781CE891F4AB4B0E4C30 /* Dictionary+Extras.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Dictionary+Extras.swift"; sourceTree = ""; }; A39A39D49FD8DA86F447684A /* OrderedSet+Codable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "OrderedSet+Codable.swift"; sourceTree = ""; }; A40EB7581064768B08E6C529 /* CreateProductsTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CreateProductsTest.swift; sourceTree = ""; }; + A41C1A5C575F9777BBECCB89 /* CreateXCSchemesTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CreateXCSchemesTests.swift; sourceTree = ""; }; A42EAB1A5AEF651AF8F6F865 /* CreateFilesAndGroupsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CreateFilesAndGroupsTests.swift; sourceTree = ""; }; A4E0D9481DEB5CB89790C09F /* PBXTargetDependency.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PBXTargetDependency.swift; sourceTree = ""; }; A6E464E0F5C4A2F0ED8DBA80 /* OrderedSet+CustomStringConvertible.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "OrderedSet+CustomStringConvertible.swift"; sourceTree = ""; }; @@ -1039,6 +1041,7 @@ A40EB7581064768B08E6C529 /* CreateProductsTest.swift */, 6A9607F1AB28FE727DED4651 /* CreateProjectTests.swift */, 7025166F1EB392F463C551D2 /* CreateXcodeProjTests.swift */, + A41C1A5C575F9777BBECCB89 /* CreateXCSchemesTests.swift */, AFE5F2E4FC573D27FCB8DF34 /* CreateXCSharedDataTests.swift */, EDE03F64CA13C3461D45773E /* DisambiguateTargetsTests.swift */, 9AD16E00A1D2C82B5121AB89 /* FilePathResolverTests.swift */, @@ -1639,6 +1642,7 @@ 6BEEFB6F9ABBD9DE61F18D20 /* CreateFilesAndGroupsTests.swift in Sources */, 72A3C7DA6BF74DE5F2EFC28C /* CreateProductsTest.swift in Sources */, 8D60F9D1D81FEDCE8DDF6B73 /* CreateProjectTests.swift in Sources */, + A32E8CBF5EF43A7EA58020DA /* CreateXCSchemesTests.swift in Sources */, 80361D1C6E985B1C92E65811 /* CreateXCSharedDataTests.swift in Sources */, A68D64FB246101C57F8011AA /* CreateXcodeProjTests.swift in Sources */, 0680A4C2872B98AC70E3ADD4 /* DisambiguateTargetsTests.swift in Sources */, diff --git a/test/fixtures/generator/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/generator/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/generator/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/generator/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme new file mode 100644 index 0000000000..f5dd84cf8d --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..f2d84b92af --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme new file mode 100644 index 0000000000..bae59bb998 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme new file mode 100644 index 0000000000..8aad4fc889 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme new file mode 100644 index 0000000000..5d145382b8 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme new file mode 100644 index 0000000000..9fb0228629 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme new file mode 100644 index 0000000000..aa6bc18646 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme new file mode 100644 index 0000000000..cce8039a2c --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.xcscheme new file mode 100644 index 0000000000..ab83439327 --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/generator.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/tests.xcscheme b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/tests.xcscheme new file mode 100644 index 0000000000..b307c3bd4b --- /dev/null +++ b/test/fixtures/generator/bwb.xcodeproj/xcshareddata/xcschemes/tests.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwb_spec.json b/test/fixtures/generator/bwb_spec.json index fb879d0fc6..cbe1f51e70 100644 --- a/test/fixtures/generator/bwb_spec.json +++ b/test/fixtures/generator/bwb_spec.json @@ -201,6 +201,7 @@ "tools/generator/test/CreateFilesAndGroupsTests.swift", "tools/generator/test/CreateProductsTest.swift", "tools/generator/test/CreateProjectTests.swift", + "tools/generator/test/CreateXCSchemesTests.swift", "tools/generator/test/CreateXCSharedDataTests.swift", "tools/generator/test/CreateXcodeProjTests.swift", "tools/generator/test/DisambiguateTargetsTests.swift", diff --git a/test/fixtures/generator/bwx.xcodeproj/project.pbxproj b/test/fixtures/generator/bwx.xcodeproj/project.pbxproj index 097585cb8e..9cf8f30f24 100644 --- a/test/fixtures/generator/bwx.xcodeproj/project.pbxproj +++ b/test/fixtures/generator/bwx.xcodeproj/project.pbxproj @@ -63,6 +63,7 @@ 2B5CE87F591A88AE69E2EA93 /* CustomDumpRepresentable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 88789669F25DD7E154C15036 /* CustomDumpRepresentable.swift */; }; 2F23E98B7032105D6B0D28C8 /* OrderedSet+UnstableInternals.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8415E01540549AB7D9DC7775 /* OrderedSet+UnstableInternals.swift */; }; 30D5B9A89D41795BE4359B14 /* Generator+CreateXCSharedData.swift in Sources */ = {isa = PBXBuildFile; fileRef = 18A3046CDCECF5B1135A1D0E /* Generator+CreateXCSharedData.swift */; }; + 32DAC21618A93EF8DB05A889 /* CreateXCSchemesTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = FC11619155D626635A9AB65A /* CreateXCSchemesTests.swift */; }; 33B7CF1072ED2BECDE1093EE /* PBXProductType+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0926F34E2099B433D5550DCD /* PBXProductType+Extensions.swift */; }; 3468B9267DEA583FB703DC62 /* KeyedDecodingContainer+Additions.swift in Sources */ = {isa = PBXBuildFile; fileRef = FB78F15F8AFA4FD268CBC7BD /* KeyedDecodingContainer+Additions.swift */; }; 34AA2315505226D74BC238A6 /* Element.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1140300C723A6A3D0EC452A4 /* Element.swift */; }; @@ -631,6 +632,7 @@ FA83272F166637CFAFC4C79C /* OrderedDictionary+Hashable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "OrderedDictionary+Hashable.swift"; sourceTree = ""; }; FAD042334686EC625458D787 /* XCWorkspace.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XCWorkspace.swift; sourceTree = ""; }; FB78F15F8AFA4FD268CBC7BD /* KeyedDecodingContainer+Additions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "KeyedDecodingContainer+Additions.swift"; sourceTree = ""; }; + FC11619155D626635A9AB65A /* CreateXCSchemesTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CreateXCSchemesTests.swift; sourceTree = ""; }; FD68E5A7AC6AF524F6B2E4D3 /* WorkspaceSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WorkspaceSettings.swift; sourceTree = ""; }; /* End PBXFileReference section */ @@ -773,6 +775,7 @@ 798455D7A824BAB585C1E8EB /* CreateProductsTest.swift */, E200ED9999C2E4E55C7EC34E /* CreateProjectTests.swift */, 4BC5B799900C53A6F581CF62 /* CreateXcodeProjTests.swift */, + FC11619155D626635A9AB65A /* CreateXCSchemesTests.swift */, 6160799DF1E959D7EF7F1CDB /* CreateXCSharedDataTests.swift */, B85F30A6B61E80F5E31CB607 /* DisambiguateTargetsTests.swift */, 87C2FB94A951A108189B85C1 /* FilePathResolverTests.swift */, @@ -1586,6 +1589,7 @@ 250DE90578C454256F39C418 /* CreateFilesAndGroupsTests.swift in Sources */, D28AD805F11C60A1A2CEBE5A /* CreateProductsTest.swift in Sources */, 0B06F16B6814BDD36D863BDF /* CreateProjectTests.swift in Sources */, + 32DAC21618A93EF8DB05A889 /* CreateXCSchemesTests.swift in Sources */, 73AC905D0A5BCA30C4E708CE /* CreateXCSharedDataTests.swift in Sources */, 5F50664E006EE645FFC8B076 /* CreateXcodeProjTests.swift in Sources */, 3CC3CF23728FFF27C3332D92 /* DisambiguateTargetsTests.swift in Sources */, diff --git a/test/fixtures/generator/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/generator/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/generator/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/generator/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme new file mode 100644 index 0000000000..fead3e95a4 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/AEXML.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..808f383f8d --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme new file mode 100644 index 0000000000..873a98e483 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/CustomDump.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme new file mode 100644 index 0000000000..91332d7bca --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/OrderedCollections.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme new file mode 100644 index 0000000000..69f7787b8c --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/PathKit.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme new file mode 100644 index 0000000000..16da107861 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XCTestDynamicOverlay.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme new file mode 100644 index 0000000000..3916236d42 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/XcodeProj.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme new file mode 100644 index 0000000000..815a576e23 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.library.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.xcscheme new file mode 100644 index 0000000000..6d19c5a259 --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/generator.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/tests.xcscheme b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/tests.xcscheme new file mode 100644 index 0000000000..720407749e --- /dev/null +++ b/test/fixtures/generator/bwx.xcodeproj/xcshareddata/xcschemes/tests.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/generator/bwx_spec.json b/test/fixtures/generator/bwx_spec.json index c8a10a0042..9666b19f72 100644 --- a/test/fixtures/generator/bwx_spec.json +++ b/test/fixtures/generator/bwx_spec.json @@ -198,6 +198,7 @@ "tools/generator/test/CreateFilesAndGroupsTests.swift", "tools/generator/test/CreateProductsTest.swift", "tools/generator/test/CreateProjectTests.swift", + "tools/generator/test/CreateXCSchemesTests.swift", "tools/generator/test/CreateXCSharedDataTests.swift", "tools/generator/test/CreateXcodeProjTests.swift", "tools/generator/test/DisambiguateTargetsTests.swift", diff --git a/test/fixtures/tvos_app/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/tvos_app/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/tvos_app/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/tvos_app/bwb.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..c580a5391f --- /dev/null +++ b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme new file mode 100644 index 0000000000..64653b97ea --- /dev/null +++ b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/Example.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..17f8d46c8f --- /dev/null +++ b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..0a5d22d95a --- /dev/null +++ b/test/fixtures/tvos_app/bwb.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/test/fixtures/tvos_app/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings index 0c67376eba..08de0be8d3 100644 --- a/test/fixtures/tvos_app/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ b/test/fixtures/tvos_app/bwx.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -1,5 +1,8 @@ - + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + diff --git a/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme new file mode 100644 index 0000000000..7bd94737d2 --- /dev/null +++ b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/BazelDependencies.xcscheme @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme new file mode 100644 index 0000000000..a44cff2cff --- /dev/null +++ b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/Example.xcscheme @@ -0,0 +1,77 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..c161fc4a98 --- /dev/null +++ b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleTests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme new file mode 100644 index 0000000000..0d5fe846cd --- /dev/null +++ b/test/fixtures/tvos_app/bwx.xcodeproj/xcshareddata/xcschemes/ExampleUITests.__internal__.__test_bundle.xcscheme @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/generator/src/Environment.swift b/tools/generator/src/Environment.swift index 9685c991fa..3c8b943401 100644 --- a/tools/generator/src/Environment.swift +++ b/tools/generator/src/Environment.swift @@ -77,8 +77,9 @@ struct Environment { ) throws -> Void let createXCSchemes: ( - _ disambiguatedTargets: [TargetID: DisambiguatedTarget] - ) -> [XCScheme] + _ filePathResolver: FilePathResolver, + _ pbxTargets: [TargetID: PBXTarget] + ) throws -> [XCScheme] let createXCSharedData: (_ schemes: [XCScheme]) -> XCSharedData diff --git a/tools/generator/src/FilePathResolver.swift b/tools/generator/src/FilePathResolver.swift index f497428e9c..7255819c5c 100644 --- a/tools/generator/src/FilePathResolver.swift +++ b/tools/generator/src/FilePathResolver.swift @@ -7,7 +7,6 @@ struct FilePathResolver: Equatable { case srcRoot } - let internalDirectoryName: String private let workspaceOutputPath: Path let internalDirectory: Path @@ -16,13 +15,14 @@ struct FilePathResolver: Equatable { /// In XcodeProj, a `referencedContainer` in a `XCScheme.BuildableReference` /// accepts a string in the format `container:`. This /// property provides the value. - lazy var containerReference = "container:\(workspaceOutputPath)" + let containerReference: String init(internalDirectoryName: String, workspaceOutputPath: Path) { self.internalDirectoryName = internalDirectoryName self.workspaceOutputPath = workspaceOutputPath internalDirectory = workspaceOutputPath + internalDirectoryName linksDirectory = internalDirectory + "links" + containerReference = "container:\(workspaceOutputPath)" } func resolve( diff --git a/tools/generator/src/Generator+AddTargets.swift b/tools/generator/src/Generator+AddTargets.swift index 731cb5ae7e..6f39b088dd 100644 --- a/tools/generator/src/Generator+AddTargets.swift +++ b/tools/generator/src/Generator+AddTargets.swift @@ -86,6 +86,10 @@ Product for target "\(id)" not found in `products` } } + if let bazelDependenciesTarget = bazelDependenciesTarget { + pbxTargets[.bazelDependencies] = bazelDependenciesTarget + } + return pbxTargets } diff --git a/tools/generator/src/Generator+CreateXCSchemes.swift b/tools/generator/src/Generator+CreateXCSchemes.swift index 8f24dd9b78..788af76436 100644 --- a/tools/generator/src/Generator+CreateXCSchemes.swift +++ b/tools/generator/src/Generator+CreateXCSchemes.swift @@ -1,11 +1,97 @@ +import PathKit import XcodeProj extension Generator { /// Creates an array of `XCScheme` entries for the specified targets. static func createXCSchemes( - disambiguatedTargets _: [TargetID: DisambiguatedTarget] - ) -> [XCScheme] { - // GH101: Implement logic to create schemes from targets. - return [] + filePathResolver: FilePathResolver, + pbxTargets: [TargetID: PBXTarget] + ) throws -> [XCScheme] { + let referencedContainer = filePathResolver.containerReference + return try pbxTargets.map { _, pbxTarget in + try createXCScheme( + referencedContainer: referencedContainer, + pbxTarget: pbxTarget + ) + } + } + + // GH399: Derive the defaultLastUpgradeVersion and defaultVersion. + private static let defaultLastUpgradeVersion = "1320" + private static let defaultVersion = "1.3" + + /// Creates an `XCScheme` for the specified target. + private static func createXCScheme( + referencedContainer: String, + pbxTarget: PBXTarget + ) throws -> XCScheme { + let buildableReference = try pbxTarget.createBuildableReference( + referencedContainer: referencedContainer + ) + let buildConfigurationName = pbxTarget.defaultBuildConfigurationName + + let buildEntries: [XCScheme.BuildAction.Entry] + let testables: [XCScheme.TestableReference] + if pbxTarget.isTestable { + buildEntries = [] + testables = [.init( + skipped: false, + buildableReference: buildableReference + )] + } else { + buildEntries = [.init( + buildableReference: buildableReference, + buildFor: [ + .running, + .testing, + .profiling, + .archiving, + .analyzing + ] + )] + testables = [] + } + let buildableProductRunnable: XCScheme.BuildableProductRunnable? = + pbxTarget.isLaunchable ? + .init(buildableReference: buildableReference) : nil + + let buildAction = XCScheme.BuildAction( + buildActionEntries: buildEntries, + parallelizeBuild: true, + buildImplicitDependencies: true + ) + let testAction = XCScheme.TestAction( + buildConfiguration: buildConfigurationName, + macroExpansion: nil, + testables: testables + ) + let launchAction = XCScheme.LaunchAction( + runnable: buildableProductRunnable, + buildConfiguration: buildConfigurationName + ) + let profileAction = XCScheme.ProfileAction( + buildableProductRunnable: buildableProductRunnable, + buildConfiguration: buildConfigurationName + ) + let analyzeAction = XCScheme.AnalyzeAction( + buildConfiguration: buildConfigurationName + ) + let archiveAction = XCScheme.ArchiveAction( + buildConfiguration: buildConfigurationName, + revealArchiveInOrganizer: true + ) + + return XCScheme( + name: pbxTarget.schemeName, + lastUpgradeVersion: defaultLastUpgradeVersion, + version: defaultVersion, + buildAction: buildAction, + testAction: testAction, + launchAction: launchAction, + profileAction: profileAction, + analyzeAction: analyzeAction, + archiveAction: archiveAction, + wasCreatedForAppExtension: nil + ) } } diff --git a/tools/generator/src/Generator.swift b/tools/generator/src/Generator.swift index 097ed7c06f..6d14ca4261 100644 --- a/tools/generator/src/Generator.swift +++ b/tools/generator/src/Generator.swift @@ -28,7 +28,7 @@ class Generator { let logger: Logger init( - environment: Environment = Generator.defaultEnvironment, + environment: Environment = Generator.defaultEnvironment, logger: Logger ) { self.logger = logger @@ -135,7 +135,10 @@ Was unable to merge "\(srcTarget.label) \ pbxTargets ) - let schemes = environment.createXCSchemes(disambiguatedTargets) + let schemes = try environment.createXCSchemes( + filePathResolver, + pbxTargets + ) let sharedData = environment.createXCSharedData(schemes) let xcodeProj = environment.createXcodeProj(pbxProj, sharedData) diff --git a/tools/generator/src/PBXTarget+Extensions.swift b/tools/generator/src/PBXTarget+Extensions.swift index 115d953c19..257689a46f 100644 --- a/tools/generator/src/PBXTarget+Extensions.swift +++ b/tools/generator/src/PBXTarget+Extensions.swift @@ -3,9 +3,9 @@ import XcodeProj public extension PBXTarget { func getBuildableName() throws -> String { - guard let buildableName = productName else { + guard let buildableName = (product?.path ?? productName) else { throw PreconditionError(message: """ -`productName` not set on target +`product` path and `productName` not set on target (\(name)) """) } return buildableName @@ -22,12 +22,13 @@ public extension PBXTarget { ) } - func getSchemeName() throws -> String { + var schemeName: String { // GH371: Update XcodeProj to support slashes in the scheme name. // The XcodeProj write logic does not like slashes (/) in the scheme // name. It fails to write with a missing folder error. - return try getBuildableName() + return name .replacingOccurrences(of: "/", with: "_") + .replacingOccurrences(of: ":", with: "_") } var isTestable: Bool { diff --git a/tools/generator/src/TargetID.swift b/tools/generator/src/TargetID.swift index c3c10cfbcc..d2b470d780 100644 --- a/tools/generator/src/TargetID.swift +++ b/tools/generator/src/TargetID.swift @@ -4,7 +4,7 @@ struct TargetID: Equatable, Hashable, Decodable { /// Creates a `TargetID` from a given `String`. init(_ id: String) { - self.rawValue = id + rawValue = id } } @@ -28,6 +28,12 @@ extension TargetID: Comparable { extension TargetID: CustomStringConvertible { var description: String { - return self.rawValue + return rawValue } } + +// MARK: Constant TargetIDs + +extension TargetID { + static let bazelDependencies = TargetID("bazel_dependencies") +} diff --git a/tools/generator/test/CreateXCSchemesTests.swift b/tools/generator/test/CreateXCSchemesTests.swift new file mode 100644 index 0000000000..98ffe75cd8 --- /dev/null +++ b/tools/generator/test/CreateXCSchemesTests.swift @@ -0,0 +1,243 @@ +import PathKit +import XcodeProj +import XCTest + +@testable import generator + +class CreateXCSchemesTests: XCTestCase { + let filePathResolver = FilePathResolver( + internalDirectoryName: "rules_xcodeproj", + workspaceOutputPath: "examples/foo/Foo.xcodeproj" + ) + let pbxTargetsDict: [TargetID: PBXTarget] = + Fixtures.pbxTargets(in: Fixtures.pbxProj(), targets: Fixtures.targets).0 + + func assertScheme( + schemesDict: [String: XCScheme], + targetID: TargetID, + shouldExpectBuildActionEntries: Bool, + shouldExpectTestables: Bool, + shouldExpectBuildableProductRunnable: Bool, + file: StaticString = #filePath, + line: UInt = #line + ) throws { + guard let target = pbxTargetsDict[targetID] else { + XCTFail( + "Did not find the target '\(targetID)'", + file: file, + line: line + ) + return + } + let schemeName = target.schemeName + guard let scheme = schemesDict[schemeName] else { + XCTFail( + "Did not find a scheme named \(schemeName)", + file: file, + line: line + ) + return + } + + // Expected values + + let expectedBuildConfigurationName = target.defaultBuildConfigurationName + let expectedBuildableReference = try target.createBuildableReference( + referencedContainer: filePathResolver.containerReference + ) + let expectedBuildActionEntries: [XCScheme.BuildAction.Entry] = + shouldExpectBuildActionEntries ? + [.init( + buildableReference: expectedBuildableReference, + buildFor: [.running, .testing, .profiling, .archiving, .analyzing] + )] : [] + let expectedTestables: [XCScheme.TestableReference] = + shouldExpectTestables ? + [.init( + skipped: false, + buildableReference: expectedBuildableReference + )] : [] + let expectedBuildableProductRunnable: XCScheme.BuildableProductRunnable? = + shouldExpectBuildableProductRunnable ? + XCScheme.BuildableProductRunnable( + buildableReference: expectedBuildableReference + ) : nil + + // Assertions + + XCTAssertNotNil( + scheme.lastUpgradeVersion, + file: file, + line: line + ) + XCTAssertNotNil( + scheme.version, + file: file, + line: line + ) + + guard let buildAction = scheme.buildAction else { + XCTFail( + "Expected a build action for \(scheme.name)", + file: file, + line: line + ) + return + } + XCTAssertEqual( + buildAction.buildActionEntries, + expectedBuildActionEntries, + "buildActionEntries did not match for \(scheme.name)", + file: file, + line: line + ) + XCTAssertTrue( + buildAction.parallelizeBuild, + "parallelizeBuild was not true for \(scheme.name)", + file: file, + line: line + ) + XCTAssertTrue( + buildAction.buildImplicitDependencies, + "buildImplicitDependencies was not true for \(scheme.name)", + file: file, + line: line + ) + + guard let testAction = scheme.testAction else { + XCTFail( + "Expected a test action for \(scheme.name)", + file: file, + line: line + ) + return + } + XCTAssertNil( + testAction.macroExpansion, + "macroExpansion was not nil for \(scheme.name)", + file: file, + line: line + ) + XCTAssertEqual( + testAction.buildConfiguration, + expectedBuildConfigurationName, + "the test action buildConfiguration did not match for \(scheme.name)", + file: file, + line: line + ) + XCTAssertEqual( + testAction.testables, + expectedTestables, + "testables did not match for \(scheme.name)", + file: file, + line: line + ) + + guard let launchAction = scheme.launchAction else { + XCTFail( + "Expected a launch action for \(scheme.name)", + file: file, + line: line + ) + return + } + XCTAssertEqual( + launchAction.buildConfiguration, + expectedBuildConfigurationName, + "the launch action buildConfiguration did not match for \(scheme.name)", + file: file, + line: line + ) + XCTAssertEqual( + launchAction.runnable, + expectedBuildableProductRunnable, + "runnable did not match for \(scheme.name)", + file: file, + line: line + ) + + guard let analyzeAction = scheme.analyzeAction else { + XCTFail( + "Expected an analyze action for \(scheme.name)", + file: file, + line: line + ) + return + } + XCTAssertEqual( + analyzeAction.buildConfiguration, + expectedBuildConfigurationName, + "the analyze action buildConfiguration did not match for \(scheme.name)", + file: file, + line: line + ) + + guard let archiveAction = scheme.archiveAction else { + XCTFail( + "Expected an archive action for \(scheme.name)", + file: file, + line: line + ) + return + } + XCTAssertEqual( + archiveAction.buildConfiguration, + expectedBuildConfigurationName, + "the archive action buildConfiguration did not match for \(scheme.name)", + file: file, + line: line + ) + XCTAssertTrue( + archiveAction.revealArchiveInOrganizer, + "revealArchiveInOrganizer did not match for \(scheme.name)", + file: file, + line: line + ) + } + + func test_createXCSchemes_withNoTargets() throws { + let schemes = try Generator.createXCSchemes( + filePathResolver: filePathResolver, + pbxTargets: [:] + ) + let expected = [XCScheme]() + XCTAssertEqual(schemes, expected) + } + + func test_createXCSchemes_withTargets() throws { + let schemes = try Generator.createXCSchemes( + filePathResolver: filePathResolver, + pbxTargets: pbxTargetsDict + ) + XCTAssertEqual(schemes.count, pbxTargetsDict.count) + + let schemesDict = Dictionary(uniqueKeysWithValues: schemes.map { ($0.name, $0) }) + + // Library + try assertScheme( + schemesDict: schemesDict, + targetID: "A 1", + shouldExpectBuildActionEntries: true, + shouldExpectTestables: false, + shouldExpectBuildableProductRunnable: false + ) + + // Testable and launchable + try assertScheme( + schemesDict: schemesDict, + targetID: "B 2", + shouldExpectBuildActionEntries: false, + shouldExpectTestables: true, + shouldExpectBuildableProductRunnable: true + ) + + // Launchable, not testable + try assertScheme( + schemesDict: schemesDict, + targetID: "A 2", + shouldExpectBuildActionEntries: true, + shouldExpectTestables: false, + shouldExpectBuildableProductRunnable: true + ) + } +} diff --git a/tools/generator/test/Fixtures.swift b/tools/generator/test/Fixtures.swift index a4986cdcf7..bfd79ad45a 100644 --- a/tools/generator/test/Fixtures.swift +++ b/tools/generator/test/Fixtures.swift @@ -1372,12 +1372,15 @@ done < "$SCRIPT_INPUT_FILE_LIST_0" pbxProj.rootObject!.targets.append(pbxTarget) } - return Dictionary( + var pbxTargets = Dictionary( uniqueKeysWithValues: pbxNativeTargets .map { targetID, pbxTarget -> (TargetID, PBXTarget) in return (targetID, pbxTarget) } ) + pbxTargets[.bazelDependencies] = bazelDependenciesTarget + + return pbxTargets } static func pbxTargets( diff --git a/tools/generator/test/GeneratorTests.swift b/tools/generator/test/GeneratorTests.swift index 0a71d39516..8af68d4ac4 100644 --- a/tools/generator/test/GeneratorTests.swift +++ b/tools/generator/test/GeneratorTests.swift @@ -45,7 +45,7 @@ final class GeneratorTests: XCTestCase { configuration: "a1b2c", product: .init(type: .staticLibrary, name: "Y", path: "") ), - "Z": Target.mock( + "Z": Target.mock( label: "//:Z", configuration: "1a2b3", product: .init(type: .application, name: "Z", path: "") @@ -64,7 +64,7 @@ final class GeneratorTests: XCTestCase { ) let rootElements = [filesAndGroups["a"]!, filesAndGroups["x"]!] let products = Fixtures.products(in: pbxProj) - + let productsGroup = PBXGroup(name: "42") let bazelDependenciesTarget = PBXAggregateTarget(name: "BD") let pbxTargets: [TargetID: PBXTarget] = [ @@ -123,7 +123,7 @@ final class GeneratorTests: XCTestCase { func processTargetMerges( targets: inout [TargetID: Target], targetMerges: [TargetID: Set] - ) throws -> Void { + ) throws { processTargetMergesCalled.append(.init( targets: targets, targetMerges: targetMerges @@ -136,8 +136,8 @@ final class GeneratorTests: XCTestCase { targetMerges: project.targetMerges )] expectedMessagesLogged.append(StubLogger.MessageLogged(.warning, """ - Was unable to merge "//:Y (a1b2c)" into "//:Z (1a2b3)" - """)) +Was unable to merge "//:Y (a1b2c)" into "//:Z (1a2b3)" +""")) // MARK: createFilesAndGroups() @@ -156,7 +156,7 @@ final class GeneratorTests: XCTestCase { extraFiles: Set, xccurrentversions: [XCCurrentVersion], filePathResolver: FilePathResolver, - logger: Logger + logger _: Logger ) -> ( files: [FilePath: File], rootElements: [PBXFileElement] @@ -336,7 +336,7 @@ final class GeneratorTests: XCTestCase { filePathResolver: filePathResolver, bazelDependenciesTarget: bazelDependenciesTarget )] - + // MARK: setTargetConfigurations() struct SetTargetConfigurationsCalled: Equatable { @@ -367,7 +367,7 @@ final class GeneratorTests: XCTestCase { disambiguatedTargets: disambiguatedTargets, pbxTargets: pbxTargets, filePathResolver: filePathResolver - ) + ), ] // MARK: setTargetDependencies() @@ -396,19 +396,25 @@ final class GeneratorTests: XCTestCase { // MARK: createXCSchemes() struct CreateXCSchemesCalled: Equatable { - let disambiguatedTargets: [TargetID: DisambiguatedTarget] + let filePathResolver: FilePathResolver + let pbxTargets: [TargetID: PBXTarget] } var createXCSchemesCalled: [CreateXCSchemesCalled] = [] func createXCSchemes( - disambiguatedTargets: [TargetID: DisambiguatedTarget] - ) -> [XCScheme] { - createXCSchemesCalled.append(.init(disambiguatedTargets: disambiguatedTargets)) + filePathResolver: FilePathResolver, + pbxTargets: [TargetID: PBXTarget] + ) throws -> [XCScheme] { + createXCSchemesCalled.append(.init( + filePathResolver: filePathResolver, + pbxTargets: pbxTargets + )) return schemes } let expectedCreateXCSchemesCalled = [CreateXCSchemesCalled( - disambiguatedTargets: disambiguatedTargets + filePathResolver: filePathResolver, + pbxTargets: pbxTargets )] // MARK: createXCSharedData() @@ -588,6 +594,7 @@ class StubLogger: Logger { case warning case error } + struct MessageLogged: Equatable { let type: MessageType let message: String @@ -597,6 +604,7 @@ class StubLogger: Logger { self.message = message } } + var messagesLogged: [MessageLogged] = [] func logDebug(_ message: @autoclosure () -> String) { diff --git a/tools/generator/test/PBXTarget+ExtensionsTests.swift b/tools/generator/test/PBXTarget+ExtensionsTests.swift index a0f884a700..8938bc451f 100644 --- a/tools/generator/test/PBXTarget+ExtensionsTests.swift +++ b/tools/generator/test/PBXTarget+ExtensionsTests.swift @@ -4,16 +4,38 @@ import XCTest @testable import generator class PBXTargetExtensionsTests: XCTestCase { - let pbxTarget = PBXTarget(name: "chicken", productName: "MyChicken") + // Need to create the PBXFileReference separate from the PBXTarget + // initializer, so that the file reference initializes properly. + // If you inline the construction of the file reference the + // product properties will not initialize properly. + let productFileReference = PBXFileReference( + path: "MyChicken.app" + ) + lazy var pbxTarget = PBXTarget( + name: "chicken", + productName: "MyChicken", + product: productFileReference + ) - func test_getBuildableName_withProductName() throws { + let pbxTargetWithoutProduct = PBXTarget( + name: "chicken", + productName: "MyChicken" + ) + + func test_getBuildableName_withProductPath() throws { let buildableName = try pbxTarget.getBuildableName() + XCTAssertEqual(buildableName, "MyChicken.app") + } + + func test_getBuildableName_withoutProductPathWithProductName() throws { + pbxTarget.product = nil + let buildableName = try pbxTargetWithoutProduct.getBuildableName() XCTAssertEqual(buildableName, "MyChicken") } - func test_getBuildableName_withoutProductName() throws { - pbxTarget.productName = nil - XCTAssertThrowsError(try pbxTarget.getBuildableName()) { error in + func test_getBuildableName_withoutProductPathAndProductName() throws { + pbxTargetWithoutProduct.productName = nil + XCTAssertThrowsError(try pbxTargetWithoutProduct.getBuildableName()) { error in guard let preconditionError = error as? PreconditionError else { XCTFail( "The thrown error was not a `PreconditionError`. \(error)" @@ -22,7 +44,7 @@ class PBXTargetExtensionsTests: XCTestCase { } XCTAssertEqual( preconditionError.message, - "`productName` not set on target" + "`product` path and `productName` not set on target (chicken)" ) } } @@ -42,18 +64,15 @@ class PBXTargetExtensionsTests: XCTestCase { } func test_getSchemeName_withSlashesInBuildableName() throws { - pbxTarget.productName = "//examples/chicken:smidgen" + pbxTarget.name = "//examples/chicken:smidgen" XCTAssertEqual( - try pbxTarget.getSchemeName(), - "__examples_chicken:smidgen" + pbxTarget.schemeName, + "__examples_chicken_smidgen" ) } func test_schemeName_withoutSlashesInBuildableName() throws { - XCTAssertEqual( - try pbxTarget.getSchemeName(), - "MyChicken" - ) + XCTAssertEqual(pbxTarget.schemeName, "chicken") } func test_isTestable_withoutProductType() throws { diff --git a/xcodeproj/internal/fixtures.bzl b/xcodeproj/internal/fixtures.bzl index 3cbce791bb..88b0b627c5 100644 --- a/xcodeproj/internal/fixtures.bzl +++ b/xcodeproj/internal/fixtures.bzl @@ -152,7 +152,6 @@ def xcodeproj_fixture( srcs = native.glob( ["{}.xcodeproj/**/*".format(suffix)], exclude = [ - "{}.xcodeproj/xcshareddata/**/*".format(suffix), "{}.xcodeproj/**/xcuserdata/**/*".format(suffix), "{}.xcodeproj/*.xcuserdatad/**/*".format(suffix), ], diff --git a/xcodeproj/internal/installer.template.sh b/xcodeproj/internal/installer.template.sh index fc23b05ec7..1bd48b8a3b 100644 --- a/xcodeproj/internal/installer.template.sh +++ b/xcodeproj/internal/installer.template.sh @@ -7,7 +7,6 @@ readonly dest="$BUILD_WORKSPACE_DIRECTORY/%output_path%" # Sync over the project, changing the permissions to be writable -# TODO: Handle schemes schemes # Don't touch project.xcworkspace as that will make Xcode prompt rsync \ --archive \ @@ -15,7 +14,6 @@ rsync \ --chmod=u+w,F-x \ --exclude=project.xcworkspace \ --exclude=xcuserdata \ - --exclude=xcshareddata/xcschemes \ --exclude=rules_xcodeproj/links \ --delete \ "$src/" "$dest/" @@ -57,9 +55,8 @@ plutil -replace IDEDidComputeMac32BitWarning -bool true "$workspace_checks" # Configure the project to use Xcode's new build system. plutil -remove BuildSystemType "$workspace_settings" > /dev/null || true -# TODO: Uncomment once we create schemes ourselves -# # Prevent Xcode from prompting the user to autocreate schemes for all targets -# plutil -replace IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded -bool false "$workspace_settings" +# Prevent Xcode from prompting the user to autocreate schemes for all targets +plutil -replace IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded -bool false "$workspace_settings" echo 'Updated project at "%output_path%"'