OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library datastore_test; | 5 library datastore_test; |
6 | 6 |
7 /// NOTE: In order to run these tests, the following datastore indices must | 7 /// NOTE: In order to run these tests, the following datastore indices must |
8 /// exist: | 8 /// exist: |
9 /// $ cat index.yaml | 9 /// $ cat index.yaml |
10 /// indexes: | 10 /// indexes: |
(...skipping 719 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
730 var sortedAndFiltered = sorted.where(filterFunction).toList(); | 730 var sortedAndFiltered = sorted.where(filterFunction).toList(); |
731 var sortedAndListFiltered = sorted.where(listFilterFunction).toList(); | 731 var sortedAndListFiltered = sorted.where(listFilterFunction).toList(); |
732 var indexedEntity = sorted.where(indexFilterMatches).toList(); | 732 var indexedEntity = sorted.where(indexFilterMatches).toList(); |
733 expect(indexedEntity.length, equals(1)); | 733 expect(indexedEntity.length, equals(1)); |
734 | 734 |
735 var filters = [ | 735 var filters = [ |
736 new Filter(FilterRelation.GreatherThan, QUERY_KEY, QUERY_LOWER_BOUND), | 736 new Filter(FilterRelation.GreatherThan, QUERY_KEY, QUERY_LOWER_BOUND), |
737 new Filter(FilterRelation.LessThan, QUERY_KEY, QUERY_UPPER_BOUND), | 737 new Filter(FilterRelation.LessThan, QUERY_KEY, QUERY_UPPER_BOUND), |
738 ]; | 738 ]; |
739 var listFilters = [ | 739 var listFilters = [ |
740 new Filter(FilterRelation.In, TEST_LIST_PROPERTY, [QUERY_LIST_ENTRY]) | 740 new Filter(FilterRelation.Equal, TEST_LIST_PROPERTY, QUERY_LIST_ENTRY) |
741 ]; | 741 ]; |
742 var indexedPropertyFilter = [ | 742 var indexedPropertyFilter = [ |
743 new Filter(FilterRelation.Equal, | 743 new Filter(FilterRelation.Equal, |
744 TEST_INDEXED_PROPERTY, | 744 TEST_INDEXED_PROPERTY, |
745 QUERY_INDEX_VALUE), | 745 QUERY_INDEX_VALUE), |
746 new Filter(FilterRelation.Equal, | 746 new Filter(FilterRelation.Equal, |
747 TEST_BLOB_INDEXED_PROPERTY, | 747 TEST_BLOB_INDEXED_PROPERTY, |
748 TEST_BLOB_INDEXED_VALUE) | 748 TEST_BLOB_INDEXED_VALUE) |
749 ]; | 749 ]; |
750 var unIndexedPropertyFilter = [ | 750 var unIndexedPropertyFilter = [ |
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1112 main() { | 1112 main() { |
1113 var scopes = datastore_impl.DatastoreImpl.SCOPES; | 1113 var scopes = datastore_impl.DatastoreImpl.SCOPES; |
1114 | 1114 |
1115 withAuthClient(scopes, (String project, httpClient) { | 1115 withAuthClient(scopes, (String project, httpClient) { |
1116 var datastore = new datastore_impl.DatastoreImpl(httpClient, 's~$project'); | 1116 var datastore = new datastore_impl.DatastoreImpl(httpClient, 's~$project'); |
1117 return cleanupDB(datastore, null).then((_) { | 1117 return cleanupDB(datastore, null).then((_) { |
1118 return runE2EUnittest(() => runTests(datastore, null)); | 1118 return runE2EUnittest(() => runTests(datastore, null)); |
1119 }); | 1119 }); |
1120 }); | 1120 }); |
1121 } | 1121 } |
OLD | NEW |