notomo / vusted

A busted wrapper for testing neovim plugin
https://luarocks.org/modules/notomo/vusted
MIT License
78 stars 4 forks source link

currentline is nil #8

Closed glepnir closed 1 year ago

glepnir commented 1 year ago

run vusted tests it works fine. all test case passed. run in github workflow I got this error

not ok 1 - 
...im/.luarocks/share/lua/5.1/busted/outputHandlers/TAP.lua:44: attempt to concatenate field 'currentline' (a nil value)

mine ci.yml is

  test:
    runs-on: ubuntu-latest
    name: test
    steps:
      - uses: rhysd/action-setup-vim@v1
        id: vim
        with:
          neovim: true
          version: nightly

      - name: luajit
        uses: leafo/gh-actions-lua@v8
        with:
          luaVersion: "luajit-2.1.0-beta3"

      - name: luarocks
        uses: leafo/gh-actions-luarocks@v4

      - name: run test
        shell: bash
        run: |
          luarocks install luacheck
          luarocks install vusted
          vusted tests
notomo commented 1 year ago

Thanks for reporting.

Currently, vusted seems to raise error when test cases are not found.

Would you confirm whether your actual ci.yml executes checkout action?

notomo commented 1 year ago

📝

Currently, vusted seems to raise error when test cases are not found.

related? https://github.com/lunarmodules/busted/issues/569

glepnir commented 1 year ago

right . missing checkout in this step. thx

Julian commented 1 year ago

Perhaps worth reopening this anyhow? It's at least a confusing error message which I just got it the first time trying out vusted (which I expected to have nothing happen essentially, as I haven't written any tests yet.)

notomo commented 1 year ago

📝created PR for busted: https://github.com/lunarmodules/busted/pull/731

notomo commented 1 year ago

fixed: notomo/vusted@c9e9048