Skip to content

Commit 9271067

Browse files
committed
Remove remaining FieldValue factory method usages.
1 parent 2333e8d commit 9271067

File tree

2 files changed

+2
-39
lines changed

2 files changed

+2
-39
lines changed

Firestore/Example/Tests/API/FIRFieldValueTests.mm

Lines changed: 1 addition & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,8 @@
1414
* limitations under the License.
1515
*/
1616

17-
#import <FirebaseFirestore/FIRBsonBinaryData.h>
18-
#import <FirebaseFirestore/FIRBsonObjectId.h>
19-
#import <FirebaseFirestore/FIRBsonTimestamp.h>
2017
#import <FirebaseFirestore/FIRFieldValue.h>
21-
#import <FirebaseFirestore/FIRInt32Value.h>
22-
#import <FirebaseFirestore/FIRRegexValue.h>
2318
#import <FirebaseFirestore/FIRVectorValue.h>
24-
#import "Firestore/Example/Tests/Util/FSTHelpers.h"
2519

2620
#import <XCTest/XCTest.h>
2721

@@ -48,38 +42,6 @@ - (void)testEquals {
4842
XCTAssertNotEqual([deleted hash], [serverTimestamp hash]);
4943
}
5044

51-
- (void)testCanCreateRegexValue {
52-
FIRRegexValue *regex = [FIRFieldValue regexWithPattern:@"^foo" options:@"x"];
53-
XCTAssertEqual(regex.pattern, @"^foo");
54-
XCTAssertEqual(regex.options, @"x");
55-
}
56-
57-
- (void)testCanCreateInt32Value {
58-
FIRInt32Value *int1 = [FIRFieldValue int32WithValue:1234];
59-
XCTAssertEqual(int1.value, 1234);
60-
61-
FIRInt32Value *int2 = [FIRFieldValue int32WithValue:-1234];
62-
XCTAssertEqual(int2.value, -1234);
63-
}
64-
65-
- (void)testCanCreateBsonObjectId {
66-
FIRBsonObjectId *objectId = [FIRFieldValue bsonObjectIdWithValue:@"foo"];
67-
XCTAssertEqual(objectId.value, @"foo");
68-
}
69-
70-
- (void)testCanCreateBsonTimestamp {
71-
FIRBsonTimestamp *timestamp = [FIRFieldValue bsonTimestampWithSeconds:123 increment:456];
72-
XCTAssertEqual(timestamp.seconds, 123U);
73-
XCTAssertEqual(timestamp.increment, 456U);
74-
}
75-
76-
- (void)testCanCreateBsonBinaryData {
77-
FIRBsonBinaryData *binData = [FIRFieldValue bsonBinaryDataWithSubtype:128
78-
data:FSTTestData(1, 2, 3, -1)];
79-
XCTAssertEqual(binData.subtype, 128);
80-
XCTAssertTrue([binData.data isEqualToData:FSTTestData(1, 2, 3, -1)]);
81-
}
82-
8345
@end
8446

85-
NS_ASSUME_NONNULL_END
47+
NS_ASSUME_NONNULL_END

Firestore/core/src/index/firestore_index_value_writer.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
#include <cmath>
2020
#include <limits>
2121
#include <string>
22+
#include <vector>
2223

2324
#include "Firestore/core/src/model/resource_path.h"
2425
#include "Firestore/core/src/model/value_util.h"

0 commit comments

Comments
 (0)