Skip to content

Commit

Permalink
Revert "OR Query Implementation (#1335)" (#1399)
Browse files Browse the repository at this point in the history
This reverts commit 11332d4.
  • Loading branch information
tom-andersen authored Jul 28, 2023
1 parent b9a53cf commit daf92c8
Show file tree
Hide file tree
Showing 28 changed files with 42 additions and 2,076 deletions.
1 change: 0 additions & 1 deletion app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -518,7 +518,6 @@ if (IOS)
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/document_snapshot.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/field_path.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/field_value.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/filter.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/listener_registration.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/load_bundle_task_progress.h
${FIREBASE_SOURCE_DIR}/firestore/src/include/firebase/firestore/map_field_value.h
Expand Down
9 changes: 0 additions & 9 deletions firestore/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ set(common_SRCS
src/common/document_snapshot.cc
src/common/exception_common.cc
src/common/exception_common.h
src/common/filter.cc
src/common/field_path.cc
src/common/field_value.cc
src/common/firestore.cc
Expand Down Expand Up @@ -98,8 +97,6 @@ set(android_SRCS
src/android/field_path_portable.h
src/android/field_value_android.cc
src/android/field_value_android.h
src/android/filter_android.cc
src/android/filter_android.h
src/android/firestore_android.cc
src/android/firestore_android.h
src/android/firestore_exceptions_android.h
Expand Down Expand Up @@ -204,17 +201,13 @@ set(main_SRCS
src/main/aggregate_query_snapshot_main.h
src/main/collection_reference_main.cc
src/main/collection_reference_main.h
src/main/composite_filter_main.cc
src/main/composite_filter_main.h
src/main/converter_main.h
src/main/document_change_main.cc
src/main/document_change_main.h
src/main/document_reference_main.cc
src/main/document_reference_main.h
src/main/document_snapshot_main.cc
src/main/document_snapshot_main.h
src/main/filter_main.cc
src/main/filter_main.h
src/main/field_value_main.cc
src/main/field_value_main.h
src/main/firestore_main.cc
Expand All @@ -234,8 +227,6 @@ set(main_SRCS
src/main/transaction_main.h
src/main/user_data_converter_main.cc
src/main/user_data_converter_main.h
src/main/unary_filter_main.cc
src/main/unary_filter_main.h
src/main/util_main.h
src/main/write_batch_main.cc
src/main/write_batch_main.h)
Expand Down
2 changes: 0 additions & 2 deletions firestore/integration_test_internal/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ set(FIREBASE_INTEGRATION_TEST_PORTABLE_TEST_SRCS
# public API are performed.
src/integration_test.cc
# Internal tests below.
src/aggregate_count_test.cc
src/aggregate_query_snapshot_test.cc
src/aggregate_query_test.cc
src/bundle_test.cc
Expand All @@ -100,7 +99,6 @@ set(FIREBASE_INTEGRATION_TEST_PORTABLE_TEST_SRCS
src/document_change_test.cc
src/document_reference_test.cc
src/document_snapshot_test.cc
src/filter_test.cc
src/field_value_test.cc
src/fields_test.cc
src/firestore_test.cc
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,6 @@
12CCF1E928FDBD9F00C24941 /* set_options_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 12CCF1DF28FDBD9F00C24941 /* set_options_test.cc */; };
12D513142684C8C200A83FAA /* bundle_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 12D513132684C8C200A83FAA /* bundle_test.cc */; };
12D5131A2684C8D100A83FAA /* bundle_builder.cc in Sources */ = {isa = PBXBuildFile; fileRef = 12D513182684C8D100A83FAA /* bundle_builder.cc */; };
1BAFACA32A449C2B00834979 /* aggregate_query_snapshot_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA02A449C2B00834979 /* aggregate_query_snapshot_test.cc */; };
1BAFACA42A449C2B00834979 /* aggregate_query_snapshot_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA02A449C2B00834979 /* aggregate_query_snapshot_test.cc */; };
1BAFACA52A449C2B00834979 /* aggregate_count_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA12A449C2B00834979 /* aggregate_count_test.cc */; };
1BAFACA62A449C2B00834979 /* aggregate_count_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA12A449C2B00834979 /* aggregate_count_test.cc */; };
1BAFACA72A449C2B00834979 /* aggregate_query_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA22A449C2B00834979 /* aggregate_query_test.cc */; };
1BAFACA82A449C2B00834979 /* aggregate_query_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA22A449C2B00834979 /* aggregate_query_test.cc */; };
1BAFACAA2A449CBD00834979 /* filter_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA92A449CBD00834979 /* filter_test.cc */; };
1BAFACAB2A449CBD00834979 /* filter_test.cc in Sources */ = {isa = PBXBuildFile; fileRef = 1BAFACA92A449CBD00834979 /* filter_test.cc */; };
520BC0391C869159008CFBC3 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 520BC0381C869159008CFBC3 /* GoogleService-Info.plist */; };
5270BB448DF5ECE860FDD68B /* firebase_firestore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = EAFAF9474EC412ADCC65F2CC /* firebase_firestore.framework */; };
529226D61C85F68000C89379 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 529226D51C85F68000C89379 /* Foundation.framework */; };
Expand Down Expand Up @@ -131,10 +123,6 @@
12D513182684C8D100A83FAA /* bundle_builder.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = bundle_builder.cc; path = src/util/bundle_builder.cc; sourceTree = "<group>"; };
12D513192684C8D100A83FAA /* bundle_builder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = bundle_builder.h; path = src/util/bundle_builder.h; sourceTree = "<group>"; };
1B3D64B35A22073C76B376D5 /* libPods-integration_test_tvos.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-integration_test_tvos.a"; sourceTree = BUILT_PRODUCTS_DIR; };
1BAFACA02A449C2B00834979 /* aggregate_query_snapshot_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = aggregate_query_snapshot_test.cc; path = src/aggregate_query_snapshot_test.cc; sourceTree = "<group>"; };
1BAFACA12A449C2B00834979 /* aggregate_count_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = aggregate_count_test.cc; path = src/aggregate_count_test.cc; sourceTree = "<group>"; };
1BAFACA22A449C2B00834979 /* aggregate_query_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = aggregate_query_test.cc; path = src/aggregate_query_test.cc; sourceTree = "<group>"; };
1BAFACA92A449CBD00834979 /* filter_test.cc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = filter_test.cc; path = src/filter_test.cc; sourceTree = "<group>"; };
3DE393E827F88B06CD3C39CD /* Pods-integration_test_tvos.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-integration_test_tvos.release.xcconfig"; path = "Target Support Files/Pods-integration_test_tvos/Pods-integration_test_tvos.release.xcconfig"; sourceTree = "<group>"; };
4AAFA3E3DA9641C2E3C46C9D /* Pods_integration_test.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_integration_test.framework; sourceTree = BUILT_PRODUCTS_DIR; };
520BC0381C869159008CFBC3 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; };
Expand Down Expand Up @@ -293,10 +281,6 @@
5292271D1C85FB5500C89379 /* src */ = {
isa = PBXGroup;
children = (
1BAFACA92A449CBD00834979 /* filter_test.cc */,
1BAFACA12A449C2B00834979 /* aggregate_count_test.cc */,
1BAFACA02A449C2B00834979 /* aggregate_query_snapshot_test.cc */,
1BAFACA22A449C2B00834979 /* aggregate_query_test.cc */,
12CCF1DF28FDBD9F00C24941 /* set_options_test.cc */,
12CCF1DB28FDBD9E00C24941 /* settings_test.cc */,
12CCF1DC28FDBD9F00C24941 /* source_test.cc */,
Expand Down Expand Up @@ -592,14 +576,12 @@
D62CCBC022F367140099BE9F /* gmock-all.cc in Sources */,
D61CFBC126091C3B0035CB2A /* integration_test.cc in Sources */,
D6AAAD532606C22D0025C53B /* includes_test.cc in Sources */,
1BAFACA52A449C2B00834979 /* aggregate_count_test.cc in Sources */,
D6AAAD502606C22D0025C53B /* numeric_transforms_test.cc in Sources */,
D6ED33BE2606CD890058CBF9 /* integration_test_util.cc in Sources */,
D6C179EA22CB322900C2651A /* ios_firebase_test_framework.mm in Sources */,
12CCF1E228FDBD9F00C24941 /* source_test.cc in Sources */,
D6AAAD4C2606C22D0025C53B /* server_timestamp_test.cc in Sources */,
D6AAAD4E2606C22D0025C53B /* firestore_test.cc in Sources */,
1BAFACAA2A449CBD00834979 /* filter_test.cc in Sources */,
D6AAAD452606C22D0025C53B /* document_change_test.cc in Sources */,
D6AAAD472606C22D0025C53B /* document_snapshot_test.cc in Sources */,
D6C179E922CB322900C2651A /* ios_app_framework.mm in Sources */,
Expand All @@ -609,9 +591,7 @@
EDEEC7632800CD0000EFBAAF /* leveldb_snappy_test.cc in Sources */,
12CCF1E828FDBD9F00C24941 /* set_options_test.cc in Sources */,
D6AAAD562606C22D0025C53B /* query_network_test.cc in Sources */,
1BAFACA72A449C2B00834979 /* aggregate_query_test.cc in Sources */,
D6AAAD552606C22D0025C53B /* listener_registration_test.cc in Sources */,
1BAFACA32A449C2B00834979 /* aggregate_query_snapshot_test.cc in Sources */,
12D5131A2684C8D100A83FAA /* bundle_builder.cc in Sources */,
D6AAAD4A2606C22D0025C53B /* fields_test.cc in Sources */,
D6AAAD462606C22D0025C53B /* query_test.cc in Sources */,
Expand All @@ -630,8 +610,6 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
1BAFACAB2A449CBD00834979 /* filter_test.cc in Sources */,
1BAFACA62A449C2B00834979 /* aggregate_count_test.cc in Sources */,
BC1D6850267B00EB005DC2DA /* app_framework.cc in Sources */,
BC1D6853267B00EB005DC2DA /* transaction_extra_test.cc in Sources */,
BC1D683E267B00EB005DC2DA /* integration_test_util.cc in Sources */,
Expand All @@ -645,7 +623,6 @@
BC1D6848267B00EB005DC2DA /* sanity_test.cc in Sources */,
12CCF1E728FDBD9F00C24941 /* write_batch_test.cc in Sources */,
12CCF1E128FDBD9F00C24941 /* settings_test.cc in Sources */,
1BAFACA82A449C2B00834979 /* aggregate_query_test.cc in Sources */,
BC1D6856267B00EE005DC2DA /* ios_app_framework.mm in Sources */,
BC1D6843267B00EB005DC2DA /* numeric_transforms_test.cc in Sources */,
BC1D6844267B00EB005DC2DA /* array_transform_test.cc in Sources */,
Expand All @@ -655,7 +632,6 @@
BC1D684E267B00EB005DC2DA /* includes_test.cc in Sources */,
BC1D684C267B00EB005DC2DA /* document_change_test.cc in Sources */,
BC1D6851267B00EB005DC2DA /* firestore_integration_test.cc in Sources */,
1BAFACA42A449C2B00834979 /* aggregate_query_snapshot_test.cc in Sources */,
BC1D6838267B00EB005DC2DA /* future_test_util.cc in Sources */,
12CCF1E528FDBD9F00C24941 /* validation_test.cc in Sources */,
BC1D6839267B00EB005DC2DA /* type_test.cc in Sources */,
Expand Down
16 changes: 16 additions & 0 deletions firestore/integration_test_internal/src/aggregate_count_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@
#include "firestore_integration_test.h"
#include "util/event_accumulator.h"

#if defined(__ANDROID__)
#include "firestore/src/android/query_android.h"
#include "firestore/src/common/wrapper_assertions.h"
#endif // defined(__ANDROID__)

#include "Firestore/core/src/util/firestore_exceptions.h"
#include "firebase/firestore/firestore_errors.h"
#include "firebase_test_framework.h"
#include "gmock/gmock.h"
#include "gtest/gtest.h"

namespace firebase {
Expand Down Expand Up @@ -751,5 +757,15 @@ TEST_F(AggregateCountTest,
EXPECT_EQ(aggregate_query2, aggregate_snapshot2.query());
}

#if defined(__ANDROID__)
TEST(QueryTestAndroidStub, Construction) {
testutil::AssertWrapperConstructionContract<Query>();
}

TEST(QueryTestAndroidStub, Assignment) {
testutil::AssertWrapperAssignmentContract<Query>();
}
#endif // defined(__ANDROID__)

} // namespace firestore
} // namespace firebase
15 changes: 0 additions & 15 deletions firestore/integration_test_internal/src/aggregate_query_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@
#include "firebase/firestore.h"
#include "firestore_integration_test.h"

#if defined(__ANDROID__)
#include "firestore/src/android/aggregate_query_android.h"
#include "firestore/src/common/wrapper_assertions.h"
#endif // defined(__ANDROID__)

#include "gtest/gtest.h"

namespace firebase {
Expand Down Expand Up @@ -337,16 +332,6 @@ TEST_F(AggregateQueryTest, TestHashCode) {
AggregateQueryHash(query1.Count()));
}

#if defined(__ANDROID__)
TEST(QueryTestAndroidStub, Construction) {
testutil::AssertWrapperConstructionContract<AggregateQuery>();
}

TEST(QueryTestAndroidStub, Assignment) {
testutil::AssertWrapperAssignmentContract<AggregateQuery>();
}
#endif // defined(__ANDROID__)

} // namespace
} // namespace firestore
} // namespace firebase
Loading

0 comments on commit daf92c8

Please sign in to comment.