mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore(dotnet): no nested namespace in transport channels (#17273)
This commit is contained in:
parent
48ac918cec
commit
c7367b7065
@ -226,11 +226,6 @@ for (const [name, type] of modelTypes)
|
|||||||
for (const [name, literals] of enumTypes)
|
for (const [name, literals] of enumTypes)
|
||||||
renderEnum(name, literals);
|
renderEnum(name, literals);
|
||||||
|
|
||||||
if (process.argv[3] !== '--skip-format') {
|
|
||||||
// run the formatting tool for .NET, to ensure the files are prepped
|
|
||||||
execSync(`dotnet format "${outputDir}"`);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {string} name
|
* @param {string} name
|
||||||
*/
|
*/
|
||||||
|
@ -209,11 +209,10 @@ function writeCSharpClass(className, inheritFrom, serializedProperties) {
|
|||||||
channels_ts.push('using System.Collections.Generic;');
|
channels_ts.push('using System.Collections.Generic;');
|
||||||
channels_ts.push('using System.Text.Json.Serialization;');
|
channels_ts.push('using System.Text.Json.Serialization;');
|
||||||
channels_ts.push(``);
|
channels_ts.push(``);
|
||||||
channels_ts.push(`namespace Microsoft.Playwright.Transport.Protocol`);
|
channels_ts.push(`namespace Microsoft.Playwright.Transport.Protocol;`);
|
||||||
channels_ts.push(`{`);
|
channels_ts.push(``);
|
||||||
channels_ts.push(` internal class ${className}${inheritFrom ? ' : ' + inheritFrom : ''}`);
|
channels_ts.push(`internal class ${className}${inheritFrom ? ' : ' + inheritFrom : ''}`);
|
||||||
channels_ts.push(serializedProperties);
|
channels_ts.push(serializedProperties);
|
||||||
channels_ts.push(`}`);
|
|
||||||
channels_ts.push(``);
|
channels_ts.push(``);
|
||||||
writeFile(`${className}.cs`, channels_ts.join('\n'));
|
writeFile(`${className}.cs`, channels_ts.join('\n'));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user