File tree Expand file tree Collapse file tree 2 files changed +42
-0
lines changed
testlib/src/main/resources/groovy/greclipse/format Expand file tree Collapse file tree 2 files changed +42
-0
lines changed Original file line number Diff line number Diff line change
1
+ /*
2
+ * Copyright 2023 DiffPlug
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ package com .diffplug .spotless .extra .groovy ;
17
+
18
+ import org .junit .jupiter .api .Test ;
19
+
20
+ import com .diffplug .spotless .StepHarness ;
21
+ import com .diffplug .spotless .TestProvisioner ;
22
+
23
+ public class GrEclipseFormatterStepSpecialCaseTest {
24
+ /** https://github.com/diffplug/spotless/issues/1657 */
25
+ @ Test
26
+ public void issue_1657 () {
27
+ StepHarness .forStep (GrEclipseFormatterStep .createBuilder (TestProvisioner .mavenCentral ()).build ())
28
+ .testResourceUnaffected ("groovy/greclipse/format/SomeClass.test" );
29
+ }
30
+ }
Original file line number Diff line number Diff line change
1
+ package com.somepackage
2
+
3
+ class SomeClass {
4
+
5
+ def func(parm) {
6
+ """<tag>
7
+ ${parm == null ? "" : "<tag>$parm</tag>"}
8
+ ${parm == null ? "" : "<tag>$parm</tag>"}
9
+ </tag>
10
+ """
11
+ }
12
+ }
You can’t perform that action at this time.
0 commit comments