New test-in-mudlet GitHub Action

As part of eliminating my remaining excuses for not properly testing all my Mudlet packages, I repackaged Busted for use in Mudlet on Windows. In the process, I realized I really ought to make it so GitHub could do the automated running for me, even if I had made it so I could test easily when booted into Windows and even get nice color output.

So I set out to make a GitHub action which would mimic the steps already in use in Mudlet’s build tasks to run our Busted tests for Mudlet itself. And now I have the MDK building and testing automatically when I make a pull request. You can view the action on the marketplace. Here’s the workflow I use for the MDK now.

name: CI

on:
  push:
    branches: [ main ]
  pull_request:
    branches: [ main ]
  
  workflow_dispatch:

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v2
      
      - name: Muddle
        uses: demonnic/build-with-muddler@v1.3
      
      - name: Upload MPackage
        uses: actions/upload-artifact@v2
        with:
          name: MDK-package
          path: build/tmp/
      
      - name: Run Busted tests
        uses: demonnic/test-in-mudlet@v1.1
        with:
          pretestPackage: ${{ github.workspace }}/build/MDK.mpackage

And an action shot.