anderseknert, to random
@anderseknert@hachyderm.io avatar

While there are still vocal proponents of , , & variations, it struck me today that people getting into software development now probably don’t realize how hyped those concepts were a decade-ish ago. These days they feel more like a personal preference for some than an organizational, or even team, decision.

I’d attribute some of that to the shift towards statically types languages, but also that the developer role today feels more individualistic in general.

joelving, to random

Encouraged by people like @jasongorman, I'm giving a proper go during the scarce free time of my parental leave.

So far it's rubbing me all the wrong ways. The bottom-up approach runs very counter to my preferred way of thinking, where I sketch out the big picture and then fill out the details.

On the other hand, in the couple of hours it took me to recreate a part of a hobby project, it uncovered a design flaw that would have taken me an order of magnitude more hours to rectify later. 😍

kerfuffle, to random
@kerfuffle@mastodon.online avatar

It baffles me how easy some people are to dismiss techniques and perspectives that are advocated by developers as "something for developers" and thus not for business or product management:

These are all concepts meant to improve delivering the right product and delivering the product right. Thinking it's merely developers doing their thing outside the realm or concern of product management is so detrimental to both.

anderseknert, to random
@anderseknert@hachyderm.io avatar

I’ve seen a lot of wrong takes on test driven development, or , lately. Surprising, given that it’s just 3 simple steps to remember:

  1. Write a unit test before writing code
  2. Write the code to be tested
  3. Tell everyone you’re doing TDD. Tell your friends, your family and your colleagues. Most importantly, tell the internet. Everyone must know you’re doing TDD. This is the most important step, and in fact, you can probably skip the first two steps and go straight to this one.
M0CUV, to forth
@M0CUV@mastodon.radio avatar

I know exactly what the problem is with eForth: I’m testing manually by poring over emulator execution traces; I’m not writing tests. I know the inner interpreter and some code words work, so I guess I’ll have to write a test framework out of that, and then test the effects of every other word until I’ve worked it all out.

jbrains, to random
@jbrains@mastodon.social avatar

I encountered this today:

> After 2 decades of doing TDD and BDD, I've realized that ignoring design and thinking that TDD will do a decent job at it for a trade-off for quicker/higher-quality development with the extra time was entirely a scam.

I react in two ways:

  1. Yes, ignoring design seems risky and invites failure.
  2. I don't know how to "do TDD and BDD" while ignoring design.

On the contrary, I do and teach #TDD as a mechanism for learning how to design "better".

How odd.

probablyfine, to random

An underrated approach to test-driving code is taking advantage of unrolled loops.

This pairs extremely well with the zero, one, many approach where you start with the empty case, then add logic to support a single input, then add logic to support two inputs, and so on.

We can use this approach to de-risk the jump from "single input" to "multiple inputs".

if (input.size() == 1) {  
 // One element case  
else if (input.size() == 2) {  
 // Two elements case  
} else if (...) {  
 // And so on  
}   

Our goal, then, is to refactor the contents of each block to look as similar as possible, such that extracting out a loop rather than a multi-step conditional is a task that can be delegated to your tooling or IDE.

Structuring your incremental test-drive development in this way may seem counter-intuitive, but it's another example of staging out low-risk changes and refactoring duplication out into a clearer form.

janriemer, to rust

The feeling when you bang your head against the wall for 3 hours and then just try something, but don't really believe in it and suddenly all your unit tests pass! 🎉 :awesome:

This is the beauty of - you can just try and guess until it works.😄 It's such a funny experience!

My editor showing the content of the previously mentioned test that is now passing. The most important data that is tested (needs to be transpiled) looks like an SQL statement (but it is not SQL, rather a weird dialect) with a join clause that consists of complicated parentheses and logical operators like "&&" and "||".

bradwilson, to random
@bradwilson@mastodon.social avatar

Last year I did #AdventOfCode live streams, working to solve them as quickly as possible when the problems went live.

I usually get to some point where the problems hit skills I don't have (usually math skills) which often led to struggle streams that inevitably gets cut off so I can just go think about the problem.

I also did one after the fact video about applying #tdd to AoC. I decided this year that's all I'm going to do: a handful of problems from a TDD perspective, to teach technique.

eldamir, to dotnet
@eldamir@hachyderm.io avatar

I feel like #TDD it’s a moving target for me working in a legacy code base. I am constantly pleasantly surprised when my tests save my skin and I can refactor things with some confidence. But writing the tests and writing them well is so hard, when there is no underlying design in the project to follow 😅

What’s a good place to go from zero to hero with TDD in #dotnet projects? Any reasonably priced courses or tutorials to recommend?

bradwilson, to dotnet
@bradwilson@mastodon.social avatar

If @xunit were a human, it would be able to drive today. 😂 Happy 16th birthday!

jitterted, to Java
@jitterted@sfba.social avatar

I think one of the biggest shifts over the past year in how I write server-side generated HTML (Thymeleaf + Spring MVC) is trying to completely avoid any decision-making logic (is there any other kind? 😏) in the template, and push all of the logic into the back-end (Controller or DTO).

This may not always be possible, but it does mean that such logic is much easier to test (and therefore test-drive).

Mike Rizzi and I have been live coding a small app where today, we did exactly that. You can see the whole playlist (we're up to 5 episodes) here: https://www.youtube.com/playlist?list=PLBHctPrH7Z2-nyaHBETfklyqddmEZUp95

Join my Discord community to talk about these episodes, #Java coding, design, architecture, #TDD, #DDD, and more: https://ted.dev/discord

jitterted, to languagelearning
@jitterted@sfba.social avatar

This book chapter is very relevant to me as I think about expanding JitterTed's #TDD Game (https://tddga.me)...

"Board Games as Part of Effective Game-Based Learning Strategies"

https://link.springer.com/referenceworkentry/10.1007/978-3-319-17461-7_142

#EducationalGames #Learning

kevinrutherford, to random
@kevinrutherford@mastodon.me.uk avatar

It's the second week of the month, and that means only one (important) thing: XP Manchester!

This monthly lean coffee discussion of all things eXtreme Programming is online, so you can attend from anywhere!

Thursday 8th February, 0730 for a 0745 start, finishing around 0845. Joining details: https://www.meetup.com/xp-manchester/.

Come along and meet the other 17 people who have already signed up to attend...

#xp #extremeprogramming #agile #tdd #xpman

khalidabuhakmeh, to CSharp
@khalidabuhakmeh@mastodon.social avatar

I’m hosting Chris Simon on a #JetBrains #livestream to discuss #TDD, #DDD, and #csharp. Not to be confused with D&D, which is about wizards, dragons, and dungeon masters… wait it's pretty similar.

#dotnet

https://www.youtube.com/live/gXz7gKtRVpM?si=Uc_kn-GzdEIvSR_p

khalidabuhakmeh, to dotnet
@khalidabuhakmeh@mastodon.social avatar

🔮 We’re doing a in the FUTURE today with Chris Simon. (Actually, he’s just in Australia, but he’s a full day ahead!)

👨‍🏫 He’ll teach us about , , and . Please come hang out in the chat. It's always so lively and fun.

👍 Boosts appreciated.

https://www.youtube.com/watch?v=gXz7gKtRVpM

abcdw, to random
@abcdw@fosstodon.org avatar

Implemented bencode encoding/decoding in Guile Scheme.

TDD is a pleasure, when you have proper tools and can [re]run specific test groups instantly.

https://git.sr.ht/~abcdw/guile-nrepl/tree/257353b1/item/src/bencode.scm

#guile #scheme #lisp #tdd #emacs

jitterted, to random
@jitterted@sfba.social avatar

I never understood the request for "empirical studies" to prove this or that in software development, e.g.:

"Show me an unbiased experiment with measurable outcomes that proves that TDD makes a dev team more productive. Until then, I'll continue doing what I do now."

Let's flip that around:

"Show me an unbiased experiment with measurable outcomes that proves doing [whatever your current process is] makes a dev team more productive than doing TDD."

Unless you can do those experiments (which are extremely difficult to do), you can't use the claim that since there is no "TDD works better" study, that means that it must be worse than what you're currently doing. That's what philosophers call an "appeal to ignorance".

TDD might be worse; you might have a great process! (In which case, I'd love to try it out!) On the other hand, TDD might be better, and you're missing out on improving. Without the (possibly impossible) empirical evidence, you have to try it and see.

#Experience #TDD

nekohayo, to GNOME
@nekohayo@mastodon.social avatar

Want a nice and reliable #calendar application for #GNOME and #Linux desktops (& #mobile!) in general, based on the @EvolutionGnome data server?

Know some #C #programming and looking for a well-scoped challenge to get your feet wet and put those skills to use in #opensource?

#GNOMECalendar could really use your help to write unit tests, so that we can use #TestDrivenDevelopment #TDD #CI for #refactoring all timezones-related code and make it reliable. Now is the time!
https://fortintam.com/blog/call-for-help-writing-gnome-calendar-compliance-unit-tests/

EngineerDaryl, to python
@EngineerDaryl@fosstodon.org avatar

Gifted myself the book about PyTest by @brianokken (because I was not busy enough with all of my personal projects 😂 ). Hope this test doesn't fail: assert is_good_book.

#python #pytest #coding #tdd

dboehmer, to programming

Test Driven Development sometimes is a huge disappointment to me:

I was writing the test first, and then got really surprised that the new method can’t be called because it’s kinda not implemented. How can that be?! 😠

Oh, I see … 🤡

@Perl

davidsabine, to random
@davidsabine@mastodon.social avatar

3 myths #developers tell managers about #TDD.

  1. "TDD takes longer."
  2. "We can just write the tests after."
  3. "It's difficult to keep the tests up-to-date when requirements are changing."
schmonz, to programming

ICYMI: Got a pre-commit hook that runs #JUnit5 tests? Try "When All Tests Were Green". It's trivial to add to your build, requires no change in human behavior, and by the end of Day 1 will have saved you more time than it cost to set up.

https://schmonz.com/software/when-all-tests-were-green/

#tdd #xp #java

jitterted, to Java
@jitterted@sfba.social avatar

On today's Solo #LiveCoding stream, I'll be working on the #htmx and WebSocket portion of my Ensemble Rotation Timer.

Join me in about 25 minutes (11:30am PST | 7:30pm UTC) on Twitch: https://jitterted.stream

#Java #SpringBoot #TDD

matadan, (edited ) to random
@matadan@mastodon.social avatar

There are some really great coders who don’t get #TDD and that’s OK but I wish they would not use that misunderstanding to just proclaim that it is useless. On the other hand we need to find a way to prove the usefulness without just saying that “you are holding it wrong”.
#programming

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