magic_lobster_party

  • 0 Posts
  • 184 Comments
Joined 2 years ago
cake
Cake day: August 15th, 2024

help-circle



  • This only checks that functions are called in the right order. Not that the functions are doing the right thing or if the functions are called with the correct arguments. Quite pointless testing IMO.

    For example, it won’t capture cases where cmdChargeCreditCard returns a payment ID that exists for cmdCompleteOrder to use.

    Set up an in-memory database, or test against a real database. You don’t test side effects by pretending that the side effects are correct.





  • Haven’t started a company myself, but I’ve worked with a few people who have.

    The common theme is that you need to involve potential clients early. Understand their wants and needs. What you learn from the first interactions will likely surprise you, and greatly reshape your product vision.

    Don’t build a product in isolation for two years. That’s a sure way to make something no one wants to pay for.









  • Not the one you asked, but I don’t like XML compared to alternatives like JSON.

    The main problem with XML is that it’s an unnecessarily complicated standard. There are often multiple ways to represent the same thing, each with their own gotchas and drawbacks.

    JSON on the other hand has a much simpler standard. The entire JSON standard fits easily in one page. It’s also closer to how data is actually represented in memory. There’s often one ideal way to represent whatever you have in memory to a JSON file, and the reverse is also true.

    Despite it’s simplicity, JSON covers most cases XML would cover. Often in a more elegant way.

    If you like pain, then XML is the right choice for you.