Skip to content

Commit

Permalink
Add runtime library compatibility tests (#1058)
Browse files Browse the repository at this point in the history
* Add runtime library compatibility tests

Technical:
- Add integration tests to check compiler compatibility with the runtime library
- Remove the unused `none` keyword
- Remove debug output when hiding ambiguous methods in reflected types
- Fix broken VSCode tasks for integration tests on Windows
- Update .gitattributes to strip \r on Windows

* Test fixes:

- Bump ghul-test tool to get updated runtime for integration tests
- Fix broken pipe project tests expectations
  • Loading branch information
degory committed Feb 13, 2024
1 parent 7fbca6d commit 3530011
Show file tree
Hide file tree
Showing 512 changed files with 3,683 additions and 1,055 deletions.
46 changes: 23 additions & 23 deletions .config/dotnet-tools.json
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
{
"version": 1,
"isRoot": true,
"tools": {
"dotnet-setversion": {
"version": "2.4.0",
"commands": [
"setversion"
]
},
"ghul.test": {
"version": "1.3.0",
"commands": [
"ghul-test"
]
},
"ghul.compiler": {
"version": "0.7.2",
"commands": [
"ghul-compiler"
]
}
}
{
"version": 1,
"isRoot": true,
"tools": {
"dotnet-setversion": {
"version": "2.4.0",
"commands": [
"setversion"
]
},
"ghul.test": {
"version": "1.3.1",
"commands": [
"ghul-test"
]
},
"ghul.compiler": {
"version": "0.7.3",
"commands": [
"ghul-compiler"
]
}
}
}
32 changes: 28 additions & 4 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,4 +1,28 @@
*.l linguist-language=L
*.ghul linguist-language=Ghul
*.jay linguist-language=Jay
*.y linguist-language=Bison
* text=auto eol=lf

*.ghul text eol=lf
*.ghulproj eol=lf
*.expected eol=lf
*.warn eol=lf
*.error eol=lf
*.txt text eol=lf
*.md text eol=lf
*.html text eol=lf
*.css text eol=lf
*.js text eol=lf
*.json text eol=lf
*.xml text eol=lf
*.yml text eol=lf
*.yaml text eol=lf
*.cs text eol=lf
*.sh text eol=lf
*.bat text eol=lf
*.cmd text eol=lf
*.csv text eol=lf
*.ts text eol=lf
*.ini text eol=lf
*.log text eol=lf

*.png binary
*.exe binary
*.dll binary
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ jobs:

integration_tests:
needs: [version, bootstrap]
name: Run tests
name: Run integration tests

runs-on: ubuntu-latest
container:
Expand Down
9 changes: 9 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,15 @@
"showReuseMessage": true,
"clear": false
}
},
{
"label": "Run all project tests",
"type": "shell",
"command": "dotnet ghul-test --use-dotnet-build project-tests",
"group": "test",
"dependsOn": [
"Publish"
]
}
]
}
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<Version>0.7.3-alpha.51</Version>
<Version>0.7.4-alpha.52</Version>
<NoWarn>$(NoWarn);NU1507</NoWarn>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<ItemGroup>
<!-- ghūl runtime -->
<PackageVersion Include="ghul.runtime" Version="1.3.0" />
<PackageVersion Include="ghul.runtime" Version="1.3.1" />

<!-- ghūl compiler dependencies -->
<PackageVersion Include="System.Reflection.MetadataLoadContext" Version="8.0.0" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
4 changes: 2 additions & 2 deletions integration-tests/execution/arithmetic-int/.vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
4 changes: 2 additions & 2 deletions integration-tests/execution/array-argument/.vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"tasks": [
{
"label": "Run test",
"command": "dotnet ghul-test ${workspaceFolder}",
"command": "dotnet ghul-test \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "test",
Expand All @@ -12,7 +12,7 @@
},
{
"label": "Capture test expectation",
"command": "../../../tasks/capture.sh ${workspaceFolder}",
"command": "../../../tasks/capture.sh \"${workspaceFolder}\"",
"type": "shell",
"group": {
"kind": "build",
Expand Down
Loading

0 comments on commit 3530011

Please sign in to comment.