Commit ee1f78c
authored
Eliminate generation of config files multiple times in the integration test pipelines (#1910)
## Why make this change?
- Closes #1909
- To include CLI as part of the integration testing, config file used
for all the integration tests are generated by CLI and in turn, these
generated config files are used by the tests. The config file generation
is added as a post build event (in the CLI module) to enable generation
of config files in the a) integration testing pipelines b) local (if
developer wishes to try out the config files we've used during
development/testing.)
- At the moment, the config file generation gets triggered twice.
Ensuring that the config file generation is executed only once will
improve the time taken in the integration testing pipelines.
## What is this change?
- The config file generation gets triggered when building the 1) CLI 2)
CLI.Tests modules.
- The build step in the pipeline is broken up as two
1. Build all the non-testing modules with
`-p:generateConfigFileForDbType=<database_type>`
2. Build the test modules without any arguements. The presence of
`-p:generateConfigFileForDbType` argument determines the execution of
config generation script. So, when the test modules are built without
this argument, the config file generation script does not execute.
## Choice of the executing config generation script in CLI vs CLI.Tests
module:
The PostBuildEvent for executing the config generator scripts after
build could have been added either in `CLI` or `CLI.Tests` module. The
module where this event is added determines where the
`generateConfigFileForDbType` is used along with the `dotnet build`
command.
From the perspective of being able to execute the integration tests,
there is no difference in adding it in CLI or CLI.Tests module.
Adding it in CLI project has the additional advantages:
1) When a developer wishes to clone the repo and work with the config
files we have used thus far for development/testing, being able to
execute this post build event using the `-p:generateConfigFileForDbType`
enables them to do this. Test module does not seem to be the right place
for this.
2) Being able to validate new changes being worked on manually in local
- For these, typically the test modules are not built. For example: When
a change spans CLI + Engine modules, being able to generate the config
file and validate that the introduced changes work fine is essential.
One should be able to perform this manual validation just by building
the modules where the changes are there without requiring building the
test projects.
## How was this tested?
- [x] Executing integration tests in the pipeline manually. Also, in the
pipelines that have executed for this PR, it can be seen that the config
generation executed only once in the integration testing pipelines.
## Sample Request(s)
N/A1 parent 0829d85 commit ee1f78c
File tree
5 files changed
+72
-9
lines changed- .pipelines
5 files changed
+72
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
64 | 66 | | |
65 | 67 | | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
66 | 75 | | |
67 | 76 | | |
68 | 77 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
83 | 85 | | |
84 | 86 | | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
85 | 94 | | |
86 | 95 | | |
87 | 96 | | |
| |||
194 | 203 | | |
195 | 204 | | |
196 | 205 | | |
197 | | - | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
198 | 209 | | |
199 | | - | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
200 | 218 | | |
201 | 219 | | |
202 | 220 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
65 | 67 | | |
66 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
67 | 76 | | |
68 | 77 | | |
69 | 78 | | |
| |||
176 | 185 | | |
177 | 186 | | |
178 | 187 | | |
179 | | - | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
180 | 191 | | |
181 | | - | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
182 | 200 | | |
183 | 201 | | |
184 | 202 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
64 | 66 | | |
65 | 67 | | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
66 | 75 | | |
67 | 76 | | |
68 | 77 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
59 | 61 | | |
60 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
61 | 70 | | |
62 | 71 | | |
63 | 72 | | |
| |||
0 commit comments