swagger-api / swagger-codegen

swagger-codegen contains a template-driven engine to generate documentation, API clients and server stubs in different languages by parsing your OpenAPI / Swagger definition.
http://swagger.io
Apache License 2.0
16.9k stars 6.03k forks source link

[CSHARP] test project is generated in default sourceFolder even when sourceFolder is set #12431

Open ruimaciel opened 1 month ago

ruimaciel commented 1 month ago
Description

When creating a C# client with swagger-codegen-cli, if the user passes a config file with sourceFolder to any path other than the default then swagger-codegen-cli still outputs the test subproject to ./src.

Swagger-codegen version

3.0.57

Swagger declaration file content or url

N/A

Command line used for generation
{
    "sourceFolder":  "FooBar"
}
java -jar swagger-codegen-cli-3.0.57.jar generate -i ${OPENAPI_SPEC} \
    -l csharp \
    -c config.json 
Steps to reproduce

How to reproduce:

  1. create config.json
  2. set sourceFolder to something other than the default value of src.
  3. run swagger-codegen-cli with the config

Expected result:

Actual result:

Related issues/PRs
Suggest a fix/enhancement
ruimaciel commented 1 month ago

@mandrean as per the PR checklist, could you please take a look at PR #12432 ? Thanks!