Skip to content
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/ColMultilineItemTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.ColMultilineItemTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``two short let binding should not have extra newline`` () =
Expand Down Expand Up @@ -388,7 +389,7 @@ let blah<'a> config : Type =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true }
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/CommentTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.CommentTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``should keep sticky-to-the-left comments after nowarn directives`` () =
Expand Down Expand Up @@ -1381,7 +1382,7 @@ open Something
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/ComputationExpressionTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.ComputationExpressionTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``async workflows`` () =
Expand Down Expand Up @@ -1587,7 +1588,7 @@ let ``new line between let and let bang, 879`` () =
SpaceBeforeUppercaseInvocation = true
IndentSize = 2
SpaceAroundDelimiter = false
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
MaxInfixOperatorExpression = 50 }
|> prepend newline
|> should
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/ControlStructureTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.ControlStructureTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``if/then/else block`` () =
Expand Down Expand Up @@ -956,7 +957,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down
5 changes: 2 additions & 3 deletions src/Fantomas.Core.Tests/DallasTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``proof of concept`` () =
Expand Down Expand Up @@ -1850,9 +1851,7 @@ let someTest input1 input2 =
Expect.equal input1 input2 "didn't equal"
}
"""
{ config with
ExperimentalStroustrupStyle = true
MultilineBlockBracketsOnSameColumn = true }
{ config with MultilineBracketStyle = ExperimentalStroustrup }
|> prepend newline
|> should
equal
Expand Down
9 changes: 5 additions & 4 deletions src/Fantomas.Core.Tests/DotGetTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.DotGetTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``a TypeApp inside a DotGet should stay on the same line, 994`` () =
Expand Down Expand Up @@ -760,7 +761,7 @@ let blah =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true }
Expand Down Expand Up @@ -797,7 +798,7 @@ let blah =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true }
Expand Down Expand Up @@ -1061,7 +1062,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
MultiLineLambdaClosingNewline = true }
|> prepend newline
Expand Down Expand Up @@ -1101,7 +1102,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
MultiLineLambdaClosingNewline = true }
|> prepend newline
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/DotIndexedGetTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.DotIndexedGetTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``multiline function application inside DotIndexedGet`` () =
Expand Down Expand Up @@ -85,7 +86,7 @@ let mySampleMethod() =
SpaceBeforeLowercaseInvocation = false
SpaceBeforeColon = true
MaxIfThenElseShortWidth = 25
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down
20 changes: 10 additions & 10 deletions src/Fantomas.Core.Tests/KeepIndentInBranchTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -942,7 +942,7 @@ let main (args : Options) =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -1018,7 +1018,7 @@ let main (args : Options) =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -1099,7 +1099,7 @@ and [<CustomEquality ; NoComparison>] Bar<'context, 'a> =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
ExperimentalKeepIndentInBranch = true
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
Expand Down Expand Up @@ -1205,7 +1205,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -1272,7 +1272,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -1426,7 +1426,7 @@ module Foo =
"""
{ config with
MultiLineLambdaClosingNewline = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlternativeLongMemberDefinitions = true }
|> prepend newline
|> should
Expand Down Expand Up @@ -1934,7 +1934,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -1993,7 +1993,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
MultiLineLambdaClosingNewline = true
Expand Down Expand Up @@ -2042,7 +2042,7 @@ module Foo =
"""
{ config with
MaxLineLength = 100
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
MultiLineLambdaClosingNewline = true
ExperimentalKeepIndentInBranch = true
MaxInfixOperatorExpression = 50 }
Expand Down Expand Up @@ -2121,7 +2121,7 @@ module Foo =
"""
{ config with
MaxLineLength = 100
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
MultiLineLambdaClosingNewline = true
ExperimentalKeepIndentInBranch = true
MaxInfixOperatorExpression = 50 }
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/LambdaTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.LambdaTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``keep comment after arrow`` () =
Expand Down Expand Up @@ -424,7 +425,7 @@ let projectIntoMap projection =
SpaceAroundDelimiter = false
MaxInfixOperatorExpression = 40
MaxFunctionBindingWidth = 60
MultilineBlockBracketsOnSameColumn = true }
MultilineBracketStyle = Aligned }
|> prepend newline
|> should
equal
Expand Down
5 changes: 3 additions & 2 deletions src/Fantomas.Core.Tests/LetBindingTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.LetBindingTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``let in should be preserved`` () =
Expand Down Expand Up @@ -1650,7 +1651,7 @@ stepLog.LogInformation (
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
NewlineBetweenTypeDefinitionAndMembers = true
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
Expand Down Expand Up @@ -1701,7 +1702,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
NewlineBetweenTypeDefinitionAndMembers = true
AlignFunctionSignatureToIndentation = true
AlternativeLongMemberDefinitions = true
Expand Down
3 changes: 2 additions & 1 deletion src/Fantomas.Core.Tests/ListTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.ListTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

[<Test>]
let ``array indices`` () =
Expand Down Expand Up @@ -1943,7 +1944,7 @@ let value = [
{ config with
MaxIfThenElseShortWidth = 120
MaxArrayOrListWidth = 120
MultilineBlockBracketsOnSameColumn = true }
MultilineBracketStyle = Aligned }
|> prepend newline
|> should
equal
Expand Down
5 changes: 3 additions & 2 deletions src/Fantomas.Core.Tests/MultiLineLambdaClosingNewlineTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Fantomas.Core.Tests.MultiLineLambdaClosingNewlineTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

let defaultConfig = config

Expand Down Expand Up @@ -576,7 +577,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
MultiLineLambdaClosingNewline = true
ExperimentalKeepIndentInBranch = true }
|> prepend newline
Expand Down Expand Up @@ -622,7 +623,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
MultiLineLambdaClosingNewline = true
ExperimentalKeepIndentInBranch = true }
|> prepend newline
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ module Fantomas.Core.Tests.MultilineBlockBracketsOnSameColumnArrayOrListTests
open NUnit.Framework
open FsUnit
open Fantomas.Core.Tests.TestHelper
open Fantomas.Core.FormatConfig

let config =
{ config with
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
SpaceBeforeColon = true
SpaceBeforeSemicolon = true }

Expand Down Expand Up @@ -416,7 +417,7 @@ module Foo =
SpaceBeforeMember = true
SpaceBeforeColon = true
SpaceBeforeSemicolon = true
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
AlignFunctionSignatureToIndentation = true
MultiLineLambdaClosingNewline = true
MaxArrayOrListWidth = 40 }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ open Fantomas.Core.FormatConfig

let config =
{ config with
MultilineBlockBracketsOnSameColumn = true
MultilineBracketStyle = Aligned
SpaceBeforeColon = true
SpaceBeforeSemicolon = true }

Expand Down Expand Up @@ -1125,7 +1125,7 @@ module WatcherTests =
"""
{ config with
MaxLineLength = 80
MultilineBlockBracketsOnSameColumn = true }
MultilineBracketStyle = Aligned }
|> prepend newline
|> should
equal
Expand Down
Loading