You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+31-1Lines changed: 31 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,7 +43,7 @@ The testing target will add a header and implementation file, likely "Acceptance
43
43
Once your test target set up, add the following to your Podspec file. Use your target's name as appropriate.
44
44
45
45
target 'Acceptance Tests' do
46
-
pod 'KIF-next', '~> 2.0.0pre2'
46
+
pod 'KIF-next', '~> 2.0.0pre5'
47
47
end
48
48
49
49
After running `pod install` complete the tasks in [**Final Test Target Configurations**](#configure-the-testing-target) below for the final details on getting your tests to run.
@@ -177,6 +177,36 @@ Most of the tester actions in the test are already defined by the KIF framework,
177
177
178
178
Everything should now be configured. When you run the integration tests using the test button, ⌘U, or the Xcode 5 Test Navigator (⌘5).
179
179
180
+
Use with other testing frameworks
181
+
---------------------------------
182
+
183
+
`KIFTestCase` is not necessary for running KIF tests. Tests can run directly in `SenTestCase` or any subclass. The basic requirement is that when you call `tester` or `system`, `self` must be an instance of `SenTestCase`.
184
+
185
+
For example, the following [Specta](https://github.com/specta/specta) test works without any changes to KIF or Specta:
186
+
187
+
#import <Specta.h>
188
+
#import <KIF.h>
189
+
190
+
SpecBegin(App)
191
+
192
+
describe(@"Tab controller", ^{
193
+
194
+
it(@"should show second view when I tap on the second tab", ^{
If you want to use KIF with a test runner that does not subclass `SenTestCase`, your runner class just needs to implement the `KIFTestActorDelegate` protocol which contains two required methods.
In the first case, the test runner should log the exception and halt the test execution if `stop` is `YES`. In the second, the runner should log all the exceptions and halt the test execution if `stop` is `YES`. The exceptions take advantage of OCUnit's extensions to `NSException` with the properties `lineNumber` and `filename` to be used in recording the error's origin.
0 commit comments