Before

…lines 1–5 unchanged (5 lines)
6// Licensed under Apache License v2.0 with Runtime Library Exception
7//
8// See https://swift.org/LICENSE.txt for license information
9//
10//===----------------------------------------------------------------------===//
11
12import ArgumentParser
13import ArgumentParserTestHelpers
14import XCTest
15
16final class Tests: XCTestCase {
17 override func setUp() {
18 #if !os(Windows) && !os(WASI)
19 unsetenv("COLUMNS")
20 #endif
21 }
22}
23
24// swift-format-ignore: AlwaysUseLowerCamelCase
25// https://github.com/apple/swift-argument-parser/issues/710
26extension Tests {
…lines 27–112 unchanged (86 lines)

After

…lines 1–4 unchanged (4 lines)
5// Copyright (c) 2020 Apple Inc. and the Swift project authors
6// Licensed under Apache License v2.0 with Runtime Library Exception
7//
8// See https://swift.org/LICENSE.txt for license information
9//
10//===----------------------------------------------------------------------===//
11
12import ArgumentParserTestHelpers
13import XCTest
14
15@testable import ArgumentParser
16
17final class Tests: XCTestCase {
18 override func setUp() {
19 Platform.Environment[.columns] = nil
20 }
21}
22
23// swift-format-ignore: AlwaysUseLowerCamelCase
24// https://github.com/apple/swift-argument-parser/issues/710
25extension Tests {
…lines 26–111 unchanged (86 lines)

Before

source_file
comment "//===-------------------------------------------------------"...
comment "//"
comment "// This source file is part of the Swift Argument Parser ope"...
comment "//"
comment "// Copyright (c) 2020 Apple Inc. and the Swift project autho"...
comment "// Licensed under Apache License v2.0 with Runtime Library E"...
comment "//"
comment "// See https://swift.org/LICENSE.txt for license information"
comment "//"
comment "//===-------------------------------------------------------"...
import_declaration
import "import"
identifier
simple_identifier "ArgumentParser"
import_declaration
import "import"
identifier
simple_identifier "ArgumentParserTestHelpers"
import_declaration
import "import"
identifier
simple_identifier "XCTest"
class_declaration
modifiers
inheritance_modifier
final "final"
class "class"
type_identifier "Tests"
: ":"
inheritance_specifier
user_type
type_identifier "XCTestCase"
class_body
{ "{"
function_declaration
modifiers
member_modifier
override "override"
func "func"
simple_identifier "setUp"
( "("
) ")"
function_body
{ "{"
statements
directive
#if "#if"
! "!"
os "os"
( "("
simple_identifier "Windows"
) ")"
&& "&&"
! "!"
os "os"
( "("
simple_identifier "WASI"
) ")"
call_expression
simple_identifier "unsetenv"
call_suffix
value_arguments
( "("
value_argument
line_string_literal
" "\""
line_str_text "COLUMNS"
" "\""
) ")"
directive
#endif "#endif"
} "}"
} "}"
comment "// swift-format-ignore: AlwaysUseLowerCamelCase"
comment "// https://github.com/apple/swift-argument-parser/issues/710"
class_declaration (+879 nodes collapsed)

After

source_file
comment "//===-------------------------------------------------------"...
comment "//"
comment "// This source file is part of the Swift Argument Parser ope"...
comment "//"
comment "// Copyright (c) 2020 Apple Inc. and the Swift project autho"...
comment "// Licensed under Apache License v2.0 with Runtime Library E"...
comment "//"
comment "// See https://swift.org/LICENSE.txt for license information"
comment "//"
comment "//===-------------------------------------------------------"...
import_declaration
import "import"
identifier
simple_identifier "ArgumentParserTestHelpers"
import_declaration
import "import"
identifier
simple_identifier "XCTest"
import_declaration
modifiers
attribute
@ "@"
user_type
type_identifier "testable"
import "import"
identifier
simple_identifier "ArgumentParser"
class_declaration
modifiers
inheritance_modifier
final "final"
class "class"
type_identifier "Tests"
: ":"
inheritance_specifier
user_type
type_identifier "XCTestCase"
class_body
{ "{"
function_declaration
modifiers
member_modifier
override "override"
func "func"
simple_identifier "setUp"
( "("
) ")"
function_body
{ "{"
statements
assignment
directly_assignable_expression
call_expression
navigation_expression
simple_identifier "Platform"
navigation_suffix
. "."
simple_identifier "Environment"
call_suffix
value_arguments
[ "["
value_argument
prefix_expression
. "."
simple_identifier "columns"
] "]"
= "="
nil "nil"
} "}"
} "}"
comment "// swift-format-ignore: AlwaysUseLowerCamelCase"
comment "// https://github.com/apple/swift-argument-parser/issues/710"
class_declaration (+879 nodes collapsed)