Comments (7)
@Blind4Basics pytest
actually produces nice failure message from simple assertions.
Similar to power asserts from Groovy. So
x = 1
assert x == 2
Fails with something like
Assertion failed:
assert x == 2
| |
1 false
It can produce more useful output depending on the test case.
from runner.
Codewars can only support one test framework per language at the moment because of how the database is set up. So we won't be able to add another test framework until we do the rewrite which I'm planning to start working on after my vacation.
I personally don't like having to maintain custom frameworks when there're existing ones we can use (e.g., JS/Python/Ruby, etc.), so I'd like to deprecate them in the future for new contents. We still need to keep them for a while for existing contents though.
For Python, I like pytest
too and if I remember correctly, it supports custom reporter so it should be possible to add.
from runner.
@kazk: Thanks for quick reply. I'll wait patiently. :) Also, I completely agree with your stance on custom frameworks. Enjoy your vacation and good luck with the rewrite.
from runner.
@kazk: I came back to this after some time. I guess there's been no progress on this and the single test framework per language limitation is still there. One possible option would be to emulate the existing framework with pytest (i.e. the current framework would be an alternative syntax for pytest. Is this a sensible idea according to you?
from runner.
No progress on Codewars part.
Have you looked into if pytest
supports custom reporters?
One possible option would be to emulate the existing framework with pytest (i.e. the current framework would be an alternative syntax for pytest. Is this a sensible idea according to you?
I'll consider it if it's fully backwards compatible and also depending on the amount of effort required.
from runner.
@suic86 : but what is the feeback for the user in case a test fails? Seems to me you're comparing assert_equals
with an equivalent of expect
. Not a good idea, imo.
from runner.
For reporting pytest
results, we should be able to make custom reporter similar to https://github.com/pchomik/pytest-spec
I haven't looked into if we can simulate Codewars test framework with pytest
so please let me know if you have some proposals. I'd be surprised if it turns out possible because codewars_test
has lots of quirks.
from runner.
Related Issues (20)
- Remove Dart 2.8
- Remove Erlang OTP 20
- Remove Swift 5.0 and 5.3
- Remove Elixir 1.11
- Remove obsolete versions of Crystal
- Remove Solidity 0.4.19
- Remove C# 8
- PowerShell tests fail with no feedback HOT 3
- Add Rust v1.75.0 (Stable) HOT 1
- Add rocket for Rust
- Add SPARQL HOT 2
- Add Nim 2.0.2
- Revalidate Julia kata recognized as outdated
- Prolog: Codewars runner can't handle assertions that produce better failure message HOT 8
- Add `junit-jupiter-params` for Groovy
- Spock data-driven tests produce invalid output
- Add `junit-jupiter-params` for Kotlin
- Add C++ 20 HOT 2
- Add Java 21 HOT 2
- Add Bend
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from runner.