bpfmt: Test comment line while sorting arrays am: a74d05b939 am: 26801b1c03 am: 438d864e2f am: d46299e855 am: 82cb863d8e

Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/2593367

Change-Id: I4405727240fe1fed314dd92fdfd5bdf395636621
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
William Escande 2023-05-18 07:21:22 +00:00 committed by Automerger Merge Worker
commit 8573f723e0

View file

@ -447,6 +447,116 @@ stuff {
},
],
}
`,
},
{
input: `
// test
foo {
stuff: [
"a", // great comment
"b",
],
}
`,
output: `
// test
foo {
stuff: [
"a", // great comment
"b",
],
}
`,
},
{
input: `
// test
foo {
stuff: [
"a",
// b comment
"b",
],
}
`,
output: `
// test
foo {
stuff: [
"a",
// b comment
"b",
],
}
`,
},
{
input: `
// test
foo {
stuff: [
"a", // a comment
// b comment
"b",
],
}
`,
output: `
// test
foo {
stuff: [
"a", // a comment
// b comment
"b",
],
}
`,
},
{
input: `
// test
foo {
stuff: [
"a",
// b comment
// on multiline
"b",
],
}
`,
output: `
// test
foo {
stuff: [
"a",
// b comment
// on multiline
"b",
],
}
`,
},
{ // Line comment are treat as groups separator
input: `
// test
foo {
stuff: [
"b",
// a comment
"a",
],
}
`,
output: `
// test
foo {
stuff: [
"b",
// a comment
"a",
],
}
`,
},
}