-
Notifications
You must be signed in to change notification settings - Fork 498
Expand file tree
/
Copy pathUITextFieldRACSupportSpec.m
More file actions
42 lines (34 loc) · 985 Bytes
/
UITextFieldRACSupportSpec.m
File metadata and controls
42 lines (34 loc) · 985 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
//
// UITextFieldRACSupportSpec.m
// ReactiveObjC
//
// Created by Andrew Urban on 9/12/17.
// Copyright © 2017 GitHub. All rights reserved.
//
@import Quick;
@import Nimble;
#import "RACControlCommandExamples.h"
#import "RACTestUITextField.h"
#import "UITextField+RACCommandSupport.h"
#import "RACCommand.h"
#import "RACDisposable.h"
QuickSpecBegin(UITextFieldRACSupportSpec)
qck_describe(@"UITextField", ^{
__block UITextField *textField;
qck_beforeEach(^{
textField = [RACTestUITextField textField];
expect(textField).notTo(beNil());
});
qck_itBehavesLike(RACControlCommandExamples, ^{
return @{
RACControlCommandExampleControl: textField,
RACControlCommandExampleActivateBlock: ^(UITextField *textField) {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Warc-performSelector-leaks"
[textField sendActionsForControlEvents:UIControlEventEditingDidEndOnExit];
#pragma clang diagnostic pop
}
};
});
});
QuickSpecEnd