obsidienne

obsidienne

Hi,

Does anybody work on a test explorer ui for elixir ? Something like Rust Test Explorer ?
Thanks

Showing Posts 1 to 7

hauleth

hauleth

Do you have screenshot how does that tool look like? Or link to it?

obsidienne

obsidienne OP

Sure, some links

Here the exemple for rust, taken from vscode-rust-test-adapter and

and Test Explorer UI - Visual Studio Marketplace

tcoopman

tcoopman

I’ve been looking for this as well. I don’t think it exists and I’ve looked at some existing adapters and it’s too much work to do it quickly, but I don’t think it would be too hard.
For example looking at GitHub - connorshea/vscode-ruby-test-adapter: A Ruby test adapter extension for the VS Code Test Explorer · GitHub gives you some idea of what needs to happen

To be clear, the reason that I would like this, is not that mix test is not sufficient, but this for me really is a case where a gui can be faster to show you all the failures,…

cj5

cj5

While it would be nice to have a UI, for those who are looking for an integrated testing environment, it is possible to create tasks to run the tests inside VSCode console.

Here is how I do it. Create tasks.json inside .vscode directory

{
  "version": "2.0.0",
  "tasks": [
    {
      "label": "Run test current file",
      "type": "shell",
      "command": "mix",
      "args": [
        "test",
        "${relativeFile}"
      ],
      "presentation": {
        "echo": true,
        "reveal": "always",
        "focus": true,
        "panel": "new"
      }
    },
    {
      "label": "Run test current line",
      "type": "shell",
      "command": "mix",
      "args": [
        "test",
        "${relativeFile}:${lineNumber}"
      ],
      "presentation": {
        "echo": true,
        "reveal": "always",
        "focus": true,
        "panel": "new"
      }
    },
    {
      "label": "Run all tests",
      "type": "shell",
      "command": "mix",
      "args": [
        "test"
      ],
      "presentation": {
        "echo": true,
        "reveal": "always",
        "focus": true,
        "panel": "new"
      }
    },
    {
      "label": "Lint",
      "type": "shell",
      "command": "mix credo",
      "presentation": {
        "echo": true,
        "reveal": "always",
        "focus": true,
        "panel": "new"
      }
    }
  ]
}

And then create keybindings (by using a keybindings.json file inside .vscode or configure globally inside VSCode).

[
  {
    "key": "ctrl+i",
    "command": "workbench.action.tasks.runTask",
    "args": "Run test current file"
  },
  {
    "key": "ctrl+u",
    "command": "workbench.action.tasks.runTask",
    "args": "Run test current line"
  },
  {
    "key": "ctrl+t",
    "command": "workbench.action.tasks.runTask",
    "args": "Run all tests"
  },
  {
    "key": "ctrl+l",
    "command": "workbench.action.tasks.runTask",
    "args": "Lint"
  }
]
Sebb

Sebb

The intellij plugin has a tests-GUI.

https://github.com/KronicDeth/intellij-elixir

There is a screenshot in the readme.

adamzapasnik

adamzapasnik

I released it a few weeks ago Elixir Test Explorer - Visual Studio Marketplace
Unfortunately, it doesn’t handle umbrella projects yet, but I’m working on that.

adamzapasnik

adamzapasnik

New version v0.5.0 has been released with support for Elixir 1.14 :slight_smile:

— All posts loaded —

Where Next? Top

Trending in Discussions Top

wmnnd
Hey folks, I wanted to share with you a project I’ve been working on for a while: It’s an Open Source (AGPLv3) newsletter tool. Think Ma...
New
axelson
Hi there! :wave: @frigidcode and I (but mostly him) have been running an Elixir Book club, we’re almost done with Designing Elixir Syste...
New
alexslade
Fly’s CEO posted this recently - Turn And Face The Strange · The Fly Blog It says that Fly is going all-in on sprites, which is a worry ...
New
sntran
In my third year of college, around 2010, I found Erlang. A few years later, I found Elixir. I liked the ideas at once: many small proces...
New
Ganna
Hi everyone, I have 8 years of production experience with Erlang/OTP and I’m just starting to get to know Elixir. What would you learn f...
New
johnkirkham
A note on form. Joe Armstrong, co-creator of the Erlang programming language, died in April 2019. What follows is a work of narrative non...
New
gtcode
I’ve been tinkering with Lynx (by José) via hold_ledger. I used AI to write the code, a separate specification, the tests, and the Lean p...
New

Other Trending Topics Top

dominicletz
Hey there, I haven’t seen a list of useful Elixir specific skills for the popular AI tools yet so I’m starting one here with my first. ...
New
mudasobwa
I fully migrated to my own harness from Anthropic/Gemini and I think it’s time to share it. Welcome DSH, the DeepSeek Harness, fully writ...
New
KristerV
Hey. Is there anyone here who creates agents in their apps? Not talking about using agents, but creating them. I’m finding it pretty diff...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
webofbits
With AI doing more of the implementation work, I’ve been wondering how much coding I should deliberately keep doing myself. My main conc...
#ai
New
OndrejValenta
(I just needed to vent somewhere and LinkedIn is full of hope, or hype, I’m not sure which exactly) AI dream has many faces, but general...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews