AixLib icon indicating copy to clipboard operation
AixLib copied to clipboard

clean CI infrastructure

Open DaJansenGit opened this issue 5 years ago • 8 comments

We want to clean the CI infrastructure a bit. This includes the following tasks:

  • [x] Merge @MichaMans fork of the buildingspy with coverage included into buildingspy master (https://github.com/MichaMans/BuildingsPy) see also https://github.com/lbl-srg/BuildingsPy/issues/253

  • [x] use master of buildingspy in all CI scripts to prevent confusion

  • [x] remove travis CI and integrate html check in gitlab CI

Any further steps you would recommand @MichaMans and @PMehrfeld

DaJansenGit avatar Nov 05 '19 11:11 DaJansenGit

  • [x] Restructure bin folder like @SvenHinrichs has almost finished (This closes #738 )
  • [ ] ~Use a .env file (or something comparable) to set global variables that can then be used in the .gitlab-ci.yml for e. g. the docker tag~

PMehrfeld avatar Nov 05 '19 11:11 PMehrfeld

@PMehrfeld where ist this documented? Is there an open issue for that?

MichaMans avatar Nov 05 '19 11:11 MichaMans

@MichaMans: If I remember correctly, this is in a private fork of @SvenHinrichs in GitLab. But of course, for documentation purposes, I would request @SvenHinrichs to write down the main changes he conducted.

PMehrfeld avatar Nov 05 '19 11:11 PMehrfeld

@PMehrfeld not really necessary, was just curious about what changes he is working on. Might be good to document that in the repo in the future

MichaMans avatar Nov 05 '19 11:11 MichaMans

The following tests are newly implemented:

  • [x] check models
  • [x] check and simulate examples and validation models
  • [x] Style Check: The script uses the ModelManagement and checks the models for the correct style
  • [x] Regression Tests: New reference file must still be added

The infrastructure and tests are divided into the following topics:

  • UnitTests: Contains regressiontest, check and simulate tests
  • SyntaxtTests: Contains HTML check, style check
  • CleanUpModelica: cleanmodelica
  • Travis CI is removed.

Implemented but not yet activated

  • Automatic Merge Request
  • Creating a new Correct_HTML Branch for the corrected HTML code
  • Push the corrected code to a repository

The documentation for the CI tests can be found in the /bin folder. The new CI infrastructure is implemented in Branch issue802_CleanCI_Infrastructure.

SvenHinrichs avatar Feb 27 '20 15:02 SvenHinrichs

with the merge of #959 @SvenHinrichs did a lot of work and reached most of the golas we had. Thanks!!!

DaJansenGit avatar Jul 02 '20 12:07 DaJansenGit

The following tests are newly implemented:

  • [x] check models
  • [x] check and simulate examples and validate models
  • [x] Style Check: The script uses the ModelManagement and checks the models for the correct style Regression Tests
  • [x] HTML Check: Tests the html code in .mo files. If the code is incorrect or not formatted correctly, a new branch is created in Github. The corrected HTML code is placed in the new branch and a new pull request is created.

The infrastructure and tests are divided into the following topics:

  • UnitTests: Contains regressiontest, check and simulate tests
  • SyntaxtTests: Contains HTML check, style check
  • CleanUpModelica: cleanmodelica
  • Travis CI is removed.
  • Template: Add a new templates for ci tests : Correct only new files that were previously added in a commit (Tests run faster and the runner is less stressed).

The documentation for the CI tests can be found in the /bin folder. The new CI infrastructure is implemented in Branch issue802_CleanCI_Infrastructure.

To-Do:

  • Create a new image that include the github private key
  • Template: writes automatically a whitelist when a new version of IBPSA is merged into AixLib
  • Add new reference files for regression tests
  • activate package systems for ci tests

SvenHinrichs avatar Jul 08 '20 07:07 SvenHinrichs

To deal better with problems like mentioned in #962 we could integrate a

  • [x] test into the CI infrastructure that checks if there are regression tests .mos scripts for models which don't exist anymore.
  • [x] we could also create an automated process similar to html correct process for ref results:
    • ref results difference for a model -> create branch with new ref results -> create PR into base branch with post of gitlab-ci-bot that shows the difference between old and new ref results (see funnel or plotly)

Also we should try to integrate this autoformater for modelica into your CI structure:

  • [ ] https://github.com/urbanopt/modelica-fmt

And another point on the todo list is the

  • [x] automated ibpsa merge

DaJansenGit avatar Jul 29 '20 09:07 DaJansenGit