adamchainz, to python
@adamchainz@fosstodon.org avatar

✍️ New post with a testing tip for mocking inner imports.

https://adamj.eu/tech/2024/05/17/python-mock-inner-import/

adamchainz, to python
@adamchainz@fosstodon.org avatar

A #pytest pattern I’ve recently enjoyed using:

  1. Change some function in a way that needs fixes to call sites.
  2. Run the whole test suite with pytest.
  3. Copy the list of failing test IDs from pytest’s summary into a scratch file.
  4. Fix up the found callers.
  5. Verify everything fixed by saving the list of tests with: pytest $(cat scratch/testids.txt)

#Python #Testing

leanpub, to Java
@leanpub@mastodon.social avatar

Testing Spring Boot Applications Demystified by Philip Riecks is free with a Leanpub Reader membership! Or you can buy it for $9.00! http://leanpub.com/testing-spring-boot-applications-demystified

leanpub, to Java
@leanpub@mastodon.social avatar

Testing Spring Boot Applications Demystified by Philip Riecks is free with a Leanpub Reader membership! Or you can buy it for $9.00! http://leanpub.com/testing-spring-boot-applications-demystified

zwovierzwo, to debian

Mal eine Frage in die Gemeinschaft.
Vor längerer Zeit hatte ich Mal eine Anleitung wie man in ein #Debian stable einbaut das manche (nicht alles) Pakete aus dem #Testing oder #unstable installiert werden. Mit allen Risiken ich weiß.

Leider finde ich die nicht mehr.
Hat hier jemand einen Tipp 🤔

Danke schon mal

LateNightLinux, to linux
@LateNightLinux@mastodon.cloud avatar

Andy is a huge proponent of test-driven development and explains why – including types of code testing including unit tests and integration tests, when you actually need to run tests, how long they should take, and more.

https://www.linuxdevtime.com/linux-dev-time-episode-97/

bmispelon, to django
@bmispelon@mastodon.social avatar
predrag, to rust
@predrag@hachyderm.io avatar

cargo-semver-checks now adds the latest Rust to its CI test matrix automatically 🤩

I love automating repetitive maintenance work, and Rust 1.78 is a great real-world test case to make sure this new automation works properly. It did!
https://github.com/obi1kenobi/cargo-semver-checks/pull/773

henrikjernevad, to programming
@henrikjernevad@mastodon.social avatar

Why should you unit test? What should you unit test? And how much?

Today's blog post answers these questions and provides some helpful guidelines.

The post is actually a lightly edited extract of a book on unit testing that I started about 10 years ago but never finished. Still, it has aged reasonably well.

https://henko.net/blog/why-write-unit-tests/

#programming #unittesting #testing

leanpub, to Software
@leanpub@mastodon.social avatar

A Practical Guide to Testing in DevOps by Katrina Clokie is free with a Leanpub Reader membership! Or you can buy it for $7.99! http://leanpub.com/testingindevops

aeveltstra, to math
@aeveltstra@mastodon.social avatar

The other day my kid asks me to present math problems about area. Early middle school: simple multiplications and divisions. He got taught a formula for areas of trapezoids: A = 1/2h * (b1 + b2).

I decided to show him how to #unittest his #math solution, by giving him a different approach: A = a + 2b, where a = area of the square, and b = area of each triangle on the sides of that square.

He threw a fit and refused to accept my approach, because it wasn’t the same as he had learned.

smh

aeveltstra,
@aeveltstra@mastodon.social avatar

There’s 2 morals to this story:

  1. Educators should avoid making belief that the approach they teach is the only possible one.
  2. You cannot verify your approach by repeating it. That only tests whether it leads to the same outcome, but doesn’t verify. Instead, you need to find a different way to get to the same conclusion, and then compare.

mzikmund, to VisualStudio
@mzikmund@dotnet.social avatar

🌐 Ever wished you could share your localhost web app with the world? With Dev Tunnels, now you can! Check out my latest video to see how:

https://youtu.be/6IrPc3zU1ho

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • rosin
  • InstantRegret
  • tacticalgear
  • DreamBathrooms
  • khanakhh
  • magazineikmin
  • thenastyranch
  • Youngstown
  • GTA5RPClips
  • slotface
  • Durango
  • ethstaker
  • kavyap
  • megavids
  • vwfavf
  • everett
  • cubers
  • cisconetworking
  • ngwrru68w68
  • normalnudes
  • modclub
  • mdbf
  • osvaldo12
  • tester
  • anitta
  • Leos
  • JUstTest
  • All magazines