Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(33)

Side by Side Diff: pkg/analysis_server/test/integration/protocol_matchers.dart

Issue 449213002: Rework "analysis.updateContent" analysis server request. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 // This file has been automatically generated. Please do not edit it manually. 5 // This file has been automatically generated. Please do not edit it manually.
6 // To regenerate the file, use the script 6 // To regenerate the file, use the script
7 // "pkg/analysis_server/spec/generate_files". 7 // "pkg/analysis_server/spec/generate_files".
8 8
9 /** 9 /**
10 * Matchers for data types defined in the analysis server API 10 * Matchers for data types defined in the analysis server API
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 203
204 /** 204 /**
205 * analysis.setSubscriptions result 205 * analysis.setSubscriptions result
206 */ 206 */
207 final Matcher isAnalysisSetSubscriptionsResult = isNull; 207 final Matcher isAnalysisSetSubscriptionsResult = isNull;
208 208
209 /** 209 /**
210 * analysis.updateContent params 210 * analysis.updateContent params
211 * 211 *
212 * { 212 * {
213 * "files": Map<FilePath, ContentChange> 213 * "files": Map<FilePath, object>
214 * } 214 * }
215 */ 215 */
216 final Matcher isAnalysisUpdateContentParams = new MatchesJsonObject( 216 final Matcher isAnalysisUpdateContentParams = new MatchesJsonObject(
217 "analysis.updateContent params", { 217 "analysis.updateContent params", {
218 "files": isMapOf(isFilePath, isContentChange) 218 "files": isMapOf(isFilePath, isObject)
219 }); 219 });
220 220
221 /** 221 /**
222 * analysis.updateContent result 222 * analysis.updateContent result
223 */ 223 */
224 final Matcher isAnalysisUpdateContentResult = isNull; 224 final Matcher isAnalysisUpdateContentResult = isNull;
225 225
226 /** 226 /**
227 * analysis.updateOptions params 227 * analysis.updateOptions params
228 * 228 *
(...skipping 532 matching lines...) Expand 10 before | Expand all | Expand 10 after
761 * } 761 * }
762 */ 762 */
763 final Matcher isDebugLaunchDataParams = new MatchesJsonObject( 763 final Matcher isDebugLaunchDataParams = new MatchesJsonObject(
764 "debug.launchData params", { 764 "debug.launchData params", {
765 "executables": isListOf(isExecutableFile), 765 "executables": isListOf(isExecutableFile),
766 "dartToHtml": isMapOf(isFilePath, isListOf(isFilePath)), 766 "dartToHtml": isMapOf(isFilePath, isListOf(isFilePath)),
767 "htmlToDart": isMapOf(isFilePath, isListOf(isFilePath)) 767 "htmlToDart": isMapOf(isFilePath, isListOf(isFilePath))
768 }); 768 });
769 769
770 /** 770 /**
771 * AddContentOverlay
772 *
773 * {
774 * "type": "add"
775 * "content": String
776 * }
777 */
778 final Matcher isAddContentOverlay = new MatchesJsonObject(
779 "AddContentOverlay", {
780 "type": equals("add"),
781 "content": isString
782 });
783
784 /**
771 * AnalysisError 785 * AnalysisError
772 * 786 *
773 * { 787 * {
774 * "severity": ErrorSeverity 788 * "severity": ErrorSeverity
775 * "type": ErrorType 789 * "type": ErrorType
776 * "location": Location 790 * "location": Location
777 * "message": String 791 * "message": String
778 * "correction": optional String 792 * "correction": optional String
779 * } 793 * }
780 */ 794 */
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
842 * } 856 * }
843 */ 857 */
844 final Matcher isAnalysisStatus = new MatchesJsonObject( 858 final Matcher isAnalysisStatus = new MatchesJsonObject(
845 "AnalysisStatus", { 859 "AnalysisStatus", {
846 "analyzing": isBool 860 "analyzing": isBool
847 }, optionalFields: { 861 }, optionalFields: {
848 "analysisTarget": isString 862 "analysisTarget": isString
849 }); 863 });
850 864
851 /** 865 /**
866 * ChangeContentOverlay
867 *
868 * {
869 * "type": "change"
870 * "offset": int
871 * "oldLength": int
872 * "replacement": String
873 * }
874 */
875 final Matcher isChangeContentOverlay = new MatchesJsonObject(
876 "ChangeContentOverlay", {
877 "type": equals("change"),
878 "offset": isInt,
879 "oldLength": isInt,
880 "replacement": isString
881 });
882
883 /**
852 * CompletionId 884 * CompletionId
853 * 885 *
854 * String 886 * String
855 */ 887 */
856 final Matcher isCompletionId = isString; 888 final Matcher isCompletionId = isString;
857 889
858 /** 890 /**
859 * CompletionRelevance 891 * CompletionRelevance
860 * 892 *
861 * enum { 893 * enum {
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
956 "METHOD_NAME", 988 "METHOD_NAME",
957 "NAMED_ARGUMENT", 989 "NAMED_ARGUMENT",
958 "OPTIONAL_ARGUMENT", 990 "OPTIONAL_ARGUMENT",
959 "PARAMETER", 991 "PARAMETER",
960 "SETTER", 992 "SETTER",
961 "TOP_LEVEL_VARIABLE", 993 "TOP_LEVEL_VARIABLE",
962 "TYPE_PARAMETER" 994 "TYPE_PARAMETER"
963 ]); 995 ]);
964 996
965 /** 997 /**
966 * ContentChange
967 *
968 * {
969 * "content": String
970 * "offset": optional int
971 * "oldLength": optional int
972 * "newLength": optional int
973 * }
974 */
975 final Matcher isContentChange = new MatchesJsonObject(
976 "ContentChange", {
977 "content": isString
978 }, optionalFields: {
979 "offset": isInt,
980 "oldLength": isInt,
981 "newLength": isInt
982 });
983
984 /**
985 * DebugContextId 998 * DebugContextId
986 * 999 *
987 * String 1000 * String
988 */ 1001 */
989 final Matcher isDebugContextId = isString; 1002 final Matcher isDebugContextId = isString;
990 1003
991 /** 1004 /**
992 * DebugService 1005 * DebugService
993 * 1006 *
994 * enum { 1007 * enum {
(...skipping 563 matching lines...) Expand 10 before | Expand all | Expand 10 after
1558 * } 1571 * }
1559 */ 1572 */
1560 final Matcher isRefactoringProblemSeverity = isIn([ 1573 final Matcher isRefactoringProblemSeverity = isIn([
1561 "INFO", 1574 "INFO",
1562 "WARNING", 1575 "WARNING",
1563 "ERROR", 1576 "ERROR",
1564 "FATAL" 1577 "FATAL"
1565 ]); 1578 ]);
1566 1579
1567 /** 1580 /**
1581 * RemoveContentOverlay
1582 *
1583 * {
1584 * "type": "remove"
1585 * }
1586 */
1587 final Matcher isRemoveContentOverlay = new MatchesJsonObject(
1588 "RemoveContentOverlay", {
1589 "type": equals("remove")
1590 });
1591
1592 /**
1568 * SearchId 1593 * SearchId
1569 * 1594 *
1570 * String 1595 * String
1571 */ 1596 */
1572 final Matcher isSearchId = isString; 1597 final Matcher isSearchId = isString;
1573 1598
1574 /** 1599 /**
1575 * SearchResult 1600 * SearchResult
1576 * 1601 *
1577 * { 1602 * {
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
1841 * 1866 *
1842 * { 1867 * {
1843 * "newName": String 1868 * "newName": String
1844 * } 1869 * }
1845 */ 1870 */
1846 final Matcher isRenameOptions = new MatchesJsonObject( 1871 final Matcher isRenameOptions = new MatchesJsonObject(
1847 "rename options", { 1872 "rename options", {
1848 "newName": isString 1873 "newName": isString
1849 }); 1874 });
1850 1875
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698