Git Product home page Git Product logo

Comments (3)

mroderick avatar mroderick commented on August 18, 2024 1

With #35 merged and published, I think this is significantly improved. I think we can close this

from referee.

mantoni avatar mantoni commented on August 18, 2024

I started looking into diff output, mainly because referee is not showing a very helpful error message when assert.equals fails on comparing two objects.

It seems like most test framewoks have a useful implementation for this based on expected and actual properties exposed on thrown errors. This is the way the Node assert module creates errors and maybe referee should do the same.

It makes sense to leave this to the test runner because there users can turn the behavior on or off and it might depend on the reporter in use to which level of detail and in which format the diff can be rendered (think console vs html vs json).

This would make the multilineStringDiff implementation entirely superfluous and also give us object diffs in a supporting framework.

I ran some quick checks with Mocha and it's relatively easy to make the change.
@mroderick What do you think?

from referee.

mroderick avatar mroderick commented on August 18, 2024

I like the idea of leaving it up to the test runner, as people will like things to be as homogenous in their chosen environments.

from referee.

Related Issues (20)

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.