test: Add MeaiFunction unit tests and document vendored JsonGen code #47
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish | |
| on: | |
| push: | |
| branches: | |
| - main | |
| tags: | |
| - v** | |
| permissions: | |
| contents: write | |
| jobs: | |
| publish: | |
| name: Publish | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v5 | |
| with: | |
| dotnet-version: 9.0.x | |
| - name: Restore | |
| run: dotnet restore | |
| - name: Build | |
| run: dotnet build | |
| --configuration Release | |
| --no-restore | |
| - name: Test | |
| run: dotnet test | |
| --configuration Release | |
| --logger GitHubActions | |
| --no-build | |
| - name: Publish to NuGet | |
| run: dotnet nuget push | |
| **.nupkg | |
| --skip-duplicate | |
| --source https://api.nuget.org/v3/index.json | |
| --api-key ${{ secrets.NUGET_KEY }} | |
| trim-check: | |
| name: Trimming Check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v5 | |
| - name: Install AutoSDK CLI | |
| run: dotnet tool install --global autosdk.cli --prerelease | |
| - name: Run trimming check | |
| run: autosdk trim src/libs/CSharpToJsonSchema/CSharpToJsonSchema.csproj | |
| release: | |
| name: Release | |
| runs-on: ubuntu-latest | |
| needs: [publish] | |
| if: startsWith(github.ref, 'refs/tags/v') | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Create release | |
| run: gh release create ${{ github.ref_name }} | |
| --title "${{ github.ref_name }}" | |
| --generate-notes | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |