Swift: add unit tests to code generation

Tests can be run with
```
bazel test //swift/codegen:tests
```

Coverage can be checked installing `pytest-cov` and running
```
pytest --cov=swift/codegen swift/codegen/test
```
This commit is contained in:
Paolo Tranquilli
2022-04-26 18:22:40 +02:00
parent 2d05ea3519
commit f171ce6341
19 changed files with 1008 additions and 149 deletions

View File

@@ -40,3 +40,10 @@ repos:
language: system
entry: bazel run //swift/codegen
pass_filenames: false
- id: swift-codegen-unit-tests
name: Run Swift code generation unit tests
files: ^swift/codegen
language: system
entry: bazel test //swift/codegen:tests
pass_filenames: false