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 support & tests for XCTest sharedlibtype #1218

Merged
merged 1 commit into from
Jan 9, 2019

Conversation

Dingobloo
Copy link

@Dingobloo Dingobloo commented Jan 9, 2019

.xctest files are OSXBundles that have executable code in them that Xcode uses to populate its integrated unit testing UI. Since premake supports OSXBundles through the sharedlibtype API I extended that support to also include xctest.

My use case was wanting to use premake rather than cmake with CUTI a C++ unit testing wrapper that integrates with XCode & Visual Studio, but others may find it helpful for swift or objective-c projects that include unit tests.

Copy link
Member

@samsinsane samsinsane left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks!

@@ -306,6 +306,8 @@
if table.contains(os.getSystemTags(cfg.system), "darwin") then
if cfg.sharedlibtype == "OSXBundle" then
return "-bundle"
elseif cfg.sharedlibtype == "XCTest" then
Copy link
Member

Choose a reason for hiding this comment

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

This probably could have been an or on the previous line, but the consistency is good. 👍

@samsinsane samsinsane merged commit 46bffb2 into premake:master Jan 9, 2019
@Dingobloo Dingobloo deleted the xctest branch January 9, 2019 13:45
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.

2 participants