mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[IDE] Remove "Begin completions" and "End completions" from test cases
These test lines weren't actually providing any value and were annoying to write. Let's jut remove them.
This commit is contained in:
@@ -71,7 +71,6 @@ func getNSError() -> NSError { return NSError(domain: "", code: 1, userInfo: [:]
|
||||
func test001() {
|
||||
do {} catch #^CATCH1^#
|
||||
|
||||
// CATCH1: Begin completions
|
||||
// CATCH1-DAG: Decl[Enum]/CurrModule/TypeRelation[Convertible]: Error4[#Error4#]; name=Error4{{$}}
|
||||
// CATCH1-DAG: Decl[Class]/CurrModule/TypeRelation[Convertible]: Error3[#Error3#]; name=Error3{{$}}
|
||||
// CATCH1-DAG: Decl[Class]/CurrModule/TypeRelation[Convertible]: Error2[#Error2#]; name=Error2{{$}}
|
||||
@@ -87,7 +86,6 @@ func test002() {
|
||||
let e2 = Error2()
|
||||
throw #^THROW1^#
|
||||
|
||||
// THROW1: Begin completions
|
||||
// THROW1-DAG: Decl[Enum]/CurrModule/TypeRelation[Convertible]: Error4[#Error4#]; name=Error4{{$}}
|
||||
// THROW1-DAG: Decl[Class]/CurrModule/TypeRelation[Convertible]: Error3[#Error3#]; name=Error3{{$}}
|
||||
// THROW1-DAG: Decl[Class]/CurrModule/TypeRelation[Convertible]: Error2[#Error2#]; name=Error2{{$}}
|
||||
@@ -107,33 +105,25 @@ func test002() {
|
||||
|
||||
func test003() {
|
||||
do {} catch Error4.#^CATCH2^#
|
||||
// CATCH2: Begin completions
|
||||
// CATCH2: Decl[EnumElement]/CurrNominal: E1[#Error4#]{{; name=.+$}}
|
||||
// CATCH2: Decl[EnumElement]/CurrNominal: E2({#Int32#})[#Error4#]{{; name=.+$}}
|
||||
// CATCH2: End completions
|
||||
}
|
||||
|
||||
func test004() {
|
||||
throw Error4.#^THROW2^#
|
||||
// THROW2: Begin completions
|
||||
// THROW2: Decl[EnumElement]/CurrNominal/TypeRelation[Convertible]: E1[#Error4#]{{; name=.+$}}
|
||||
// THROW2: Decl[EnumElement]/CurrNominal/TypeRelation[Convertible]: E2({#Int32#})[#Error4#]{{; name=.+$}}
|
||||
// THROW2: End completions
|
||||
}
|
||||
|
||||
func test005() {
|
||||
do {} catch Error4.E2#^CATCH3^#
|
||||
// CATCH3: Begin completions
|
||||
// CATCH3: Pattern/CurrModule/Flair[ArgLabels]: ({#Int32#})[#Error4#]{{; name=.+$}}
|
||||
// CATCH3: End completions
|
||||
}
|
||||
|
||||
func testInvalid() {
|
||||
try throw Error4.#^THROW3^#
|
||||
// THROW3: Begin completions
|
||||
// THROW3: Decl[EnumElement]/CurrNominal/TypeRelation[Convertible]: E1[#Error4#]{{; name=.+$}}
|
||||
// THROW3: Decl[EnumElement]/CurrNominal/TypeRelation[Convertible]: E2({#Int32#})[#Error4#]{{; name=.+$}}
|
||||
// THROW3: End completions
|
||||
}
|
||||
|
||||
//===--- Top-level throw/catch
|
||||
@@ -146,13 +136,11 @@ try throw Error4.#^TOP_LEVEL_THROW3^#
|
||||
//===--- Inside catch body
|
||||
|
||||
// Statement-level code completions. This isn't exhaustive.
|
||||
// STMT: Begin completions
|
||||
// STMT-DAG: Keyword[if]/None: if; name=if
|
||||
// STMT-DAG: Decl[Class]/CurrModule: Error1[#Error1#]; name=Error1
|
||||
// STMT-DAG: Decl[Class]/CurrModule: Error2[#Error2#]; name=Error2
|
||||
// STMT-DAG: Decl[FreeFunction]/CurrModule: getError1()[#Error1#]; name=getError1()
|
||||
// STMT-DAG: Decl[FreeFunction]/CurrModule: getNSError()[#NSError#]; name=getNSError()
|
||||
// STMT: End completions
|
||||
|
||||
func test006() {
|
||||
do {
|
||||
@@ -207,7 +195,6 @@ func test012() {
|
||||
error.#^INSIDE_CATCH_ERR_DOT1^#
|
||||
}
|
||||
}
|
||||
// ERROR_DOT: Begin completions
|
||||
// ERROR_DOT: Keyword[self]/CurrNominal: self[#Error#]; name=self
|
||||
func test013() {
|
||||
do {
|
||||
@@ -220,7 +207,6 @@ func test014() {
|
||||
} catch let e as NSError {
|
||||
e.#^INSIDE_CATCH_ERR_DOT3^#
|
||||
}
|
||||
// NSERROR_DOT: Begin completions
|
||||
// NSERROR_DOT-DAG: Decl[InstanceVar]/CurrNominal/IsSystem: domain[#String#]; name=domain
|
||||
// NSERROR_DOT-DAG: Decl[InstanceVar]/CurrNominal/IsSystem: code[#Int#]; name=code
|
||||
// NSERROR_DOT-DAG: Decl[InstanceVar]/Super: hashValue[#Int#]; name=hashValue
|
||||
@@ -228,7 +214,6 @@ func test014() {
|
||||
// NSERROR_DOT-DAG: Decl[InstanceMethod]/Super/IsSystem: isEqual({#(other): NSObject!#})[#Bool#]; name=isEqual(:)
|
||||
// NSERROR_DOT-DAG: Decl[InstanceVar]/Super/IsSystem: hash[#Int#]; name=hash
|
||||
// NSERROR_DOT-DAG: Decl[InstanceVar]/Super/IsSystem: description[#String#]; name=description
|
||||
// NSERROR_DOT: End completions
|
||||
}
|
||||
func test015() {
|
||||
do {
|
||||
@@ -237,10 +222,8 @@ func test015() {
|
||||
}
|
||||
}
|
||||
// Check that we can complete on the bound value; Not exhaustive..
|
||||
// INT_DOT: Begin completions
|
||||
// INT_DOT-DAG: Decl[InstanceVar]/Super/IsSystem: bigEndian[#(Int32)#]; name=bigEndian
|
||||
// INT_DOT-DAG: Decl[InstanceVar]/Super/IsSystem: littleEndian[#(Int32)#]; name=littleEndian
|
||||
// INT_DOT: End completions
|
||||
|
||||
//===--- Inside catch body top-level
|
||||
do {
|
||||
|
||||
Reference in New Issue
Block a user