GithubHelp home page GithubHelp logo

Suggestion - Jest features about superoak HOT 4 CLOSED

cmorten avatar cmorten commented on July 28, 2024
Suggestion - Jest features

from superoak.

Comments (4)

asos-craigmorten avatar asos-craigmorten commented on July 28, 2024 1

Hi @Leonardo-Rocha, the scope of this particular project is purely around the superoak() utility to make it easier to integration test Oak applications, so this isn’t something I plan to implement here.

I appreciate that testing Deno applications as a whole isn’t very mature atm with no existing testing library currently listed in the third party modules, and this is a pain point I’ve felt, hence why I created these very minimal test utils.

Looking at the Deno core repo it looks like there is no intention to include this kind of behaviour in Deno itself, so we may need a library to emerge eventually -denoland/deno#4092.

That link does suggest some libraries are already having some success using Mocha for testing, as this has a browser mode and thus is compatible with Deno. Maybe check that out?

I might see if can put something together later in a new repo - I’ll drop a note here and will probably convert these tests over as an example.

from superoak.

asos-craigmorten avatar asos-craigmorten commented on July 28, 2024 1

@Leonardo-Rocha I have written a small blog post which demonstrates how you can use Mocha (similar to jest) to test your Deno code - check it out here: https://dev.to/craigmorten/testing-your-deno-apps-with-mocha-4f35

from superoak.

asos-craigmorten avatar asos-craigmorten commented on July 28, 2024 1

@Leonardo-Rocha the best ideas always come from real problems people have - why I always welcome issues, comments, PRs etc!

Note: I gave the suggestions without realizing the complexity of it, after taking a look at Jest source code length I instantly regretted haha

I looked at it myself a week or so back while feeling ambitious and quickly changed my mind 😂

It shouldn't be too hard to write simple hooks, but I think the effort is better placed adding wrappers, ports or using directly testing frameworks that are known to work well, have a large community of support and provide all these features already!

from superoak.

Leonardo-Rocha avatar Leonardo-Rocha commented on July 28, 2024

Thanks a lot, Craig! I read your response and I was just to reading mocha docs right now! Later I'll follow your tutorial and jump straight into Mocha. Btw I'm happy to see that you could create some content based on my suggestions. I'll also recommend your tutorial for my fellow brazilian devs.

Note: I gave the suggestions without realizing the complexity of it, after taking a look at Jest source code length I instantly regretted haha

from superoak.

Related Issues (16)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.