[cmake-developers] [PATCH 1/2] Add handling for XCTest bundles

Brad King brad.king at kitware.com
Tue Dec 9 15:41:06 EST 2014


On 12/9/2014 6:02 AM, Gregor Jasny wrote:
> +XCTEST_HOST
> +-----------
> +
> +XCTest works by injecting an XCTest CFBundle directly into an AppBundle
> +or Framework. This property names this destination target under test.

Please add mention of :prop_tgt:`XCTEST` here.

> \ No newline at end of file

Please end all sources with a newline.

> -    if (target.GetPropertyAsBool("BUNDLE"))
> +    if (target.IsCFBundleOnApple())

Please factor this refactoring hunk (and others like it, if any)
into a preceding commit with a message explaining the individual
part of the change.

> +      cmSystemTools::Error("target has XCTEST property "
> +                           "but no XCTEST_HOST one.");
[snip]
> +      cmSystemTools::Error("Cannot find XCTEST_HOST target: ", testHostName);
[snip]
> +      cmSystemTools::Error("XCTEST_HOST target is not a Framework "
> +                           "or App Bundle: ", testHostName);

These should use IssueMessage too, please.  Use the signature
that takes an explicit backtrace and pass target.GetBacktrace()
to provide some context.

Thanks,
-Brad


More information about the cmake-developers mailing list