xcake 0.7.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -1
- data/Gemfile.lock +2 -2
- data/lib/xcake/project/sugar.rb +41 -11
- data/lib/xcake/target.rb +0 -4
- data/lib/xcake/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a0fcc179fc45aaac5a2ddda294482388a957c656
|
4
|
+
data.tar.gz: 7ae7e339d3bb77f0cbd107ecb55fc7dc6f97afde
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 933ff2760e11899e5072c40e153c5097d4005778d115c4af68f022d85702e4db5013eaf6bc7113de5cfb60c2073190679711dc62345929dc38f2e0de4daaaa12
|
7
|
+
data.tar.gz: 23da41ae5939f3d965f210abdef79c687ef2fa5e22b1d1157846214851791004254634e3a46ddc199aba43ff39e12f07755d0549b3fb352e77dc7fa1a28d4bfe
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
xcake (0.7.
|
4
|
+
xcake (0.7.1)
|
5
5
|
activesupport (< 5)
|
6
6
|
claide (>= 0.9.1, < 2.0)
|
7
7
|
cork
|
@@ -83,7 +83,7 @@ GEM
|
|
83
83
|
thread_safe (~> 0.1)
|
84
84
|
uber (0.0.15)
|
85
85
|
unicode-display_width (1.1.0)
|
86
|
-
xcodeproj (1.
|
86
|
+
xcodeproj (1.3.0)
|
87
87
|
activesupport (>= 3)
|
88
88
|
claide (>= 1.0.0, < 2.0)
|
89
89
|
colored (~> 1.2)
|
data/lib/xcake/project/sugar.rb
CHANGED
@@ -42,6 +42,28 @@ module Xcake
|
|
42
42
|
end
|
43
43
|
end
|
44
44
|
|
45
|
+
# Defines a new ui test target.
|
46
|
+
#
|
47
|
+
# @param [Target] host target
|
48
|
+
# host target for which the unit tests are for.
|
49
|
+
#
|
50
|
+
# @param [Proc] block
|
51
|
+
# an optional block that configures the target through the DSL.
|
52
|
+
#
|
53
|
+
# @return [Target] the unit test target
|
54
|
+
# the newly created unit test target
|
55
|
+
#
|
56
|
+
def ui_tests_for(host_target)
|
57
|
+
target do |t|
|
58
|
+
t.name = "#{host_target.name}UITests"
|
59
|
+
|
60
|
+
t.type = :ui_test_bundle
|
61
|
+
configure_test_target_for_host_target(t, host_target)
|
62
|
+
|
63
|
+
yield(t) if block_given?
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
45
67
|
# Defines a new unit test target.
|
46
68
|
#
|
47
69
|
# @param [Target] host target
|
@@ -58,22 +80,30 @@ module Xcake
|
|
58
80
|
t.name = "#{host_target.name}Tests"
|
59
81
|
|
60
82
|
t.type = :unit_test_bundle
|
61
|
-
t
|
62
|
-
t.deployment_target = host_target.deployment_target
|
63
|
-
t.language = host_target.language
|
64
|
-
|
65
|
-
host_path = "#{host_target.name}.app/#{host_target.name}"
|
66
|
-
t.all_configurations.each do |c|
|
67
|
-
c.settings['TEST_HOST'] = "$(BUILT_PRODUCTS_DIR)/#{host_path}"
|
68
|
-
end
|
69
|
-
t.all_configurations.each do |c|
|
70
|
-
c.settings['BUNDLE_LOADER'] = '$(TEST_HOST)'
|
71
|
-
end
|
83
|
+
configure_test_target_for_host_target(t, host_target)
|
72
84
|
|
73
85
|
yield(t) if block_given?
|
74
86
|
end
|
75
87
|
end
|
76
88
|
|
89
|
+
private
|
90
|
+
|
91
|
+
def configure_test_target_for_host_target(test_target, host_target)
|
92
|
+
test_target.platform = host_target.platform
|
93
|
+
test_target.deployment_target = host_target.deployment_target
|
94
|
+
test_target.language = host_target.language
|
95
|
+
|
96
|
+
host_path = "#{host_target.name}.app/#{host_target.name}"
|
97
|
+
test_target.all_configurations.each do |c|
|
98
|
+
c.settings['TEST_HOST'] = "$(BUILT_PRODUCTS_DIR)/#{host_path}"
|
99
|
+
end
|
100
|
+
test_target.all_configurations.each do |c|
|
101
|
+
c.settings['BUNDLE_LOADER'] = '$(TEST_HOST)'
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
public
|
106
|
+
|
77
107
|
# Defines a extension target.
|
78
108
|
#
|
79
109
|
# @param [Target] host target
|
data/lib/xcake/target.rb
CHANGED
@@ -36,10 +36,6 @@ module Xcake
|
|
36
36
|
#
|
37
37
|
attr_accessor :language
|
38
38
|
|
39
|
-
# @return [Target] the test target for this target
|
40
|
-
#
|
41
|
-
attr_accessor :test_target
|
42
|
-
|
43
39
|
# @return [Array<Xcodeproj::Project::Object::AbstractBuildPhase>] the list
|
44
40
|
# of custom build phases for the project.
|
45
41
|
#
|
data/lib/xcake/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xcake
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Campbell
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|