Comments (8)
Title: Mastering Your Tools (Why don't people do this?)
Tools amplify your talent. The better your tools, and the better you know how to use them, the more productive you can be.”
― Andrew Hunt, The Pragmatic Programmer: From Journeyman to Master
from events.
hi @ttsui ! could we have the "Mastering Your Tools (Why don't people do this?)" talk in the next event https://www.meetup.com/en-AU/Software-Craftsmanship-Sydney/events/243295595/?eventId=243295595?
from events.
@rodolfoprr Sure. It'll be good if we can get a few more lightning talks. I hardly be able to fill the whole time slot.
from events.
@ttsui 15 minutes is
from events.
@rodolfoprr Sure. I can ramble on for 15.
from events.
@ttsui cool! so I'm adding your lightning talk :)
from events.
Set for September edition: https://www.meetup.com/en-AU/Software-Craftsmanship-Sydney/events/243295595/
from events.
I don't have any talk but I have a question/problem:
I have a functionality that starts with a few SQL query and then I call a pure method to format my entity. it is composed of a lot of pure function and it must take me 500 lines of highly functional code (very dense).
It looks like this
function myfunctionnality(param) {
const myData = callSQLs(param)
return formatData(data)
}
function formatData(data) {
formatEntityA(data)
formatEntityB(data)
formatEntityB(data)
}
function formatEntityA(data) {
formatEntityA1(data)
formatEntityA2(data)
formatEntityA2(data)
}
function formatEntityB(data) {
formatEntityB1(data)
formatEntityB2(data)
formatEntityB2(data)
}
...
it continues like that for 500 lines. The code is readable (could be improved a lot) but I am unsure on how to test it:
- I have chosen not to write any unit or integration on the
callSQLs
- I tested every
formatXXX
function to handle its cyclomatic complexity but without mocking the child functions.
My issue most of the time I modify the functionality of one function, it will break the parent function.
If I were to mock the child function, I would need to update those mocks.
Unfortunately, I cannot show some code because it doesn't belong to me.
Starting with this real life example we could talk about:
- Mocking strategy
- Classic TDD vs London school TDD
What do you think, could this spark a nice debate?
from events.
Related Issues (20)
- What would you say to your younger self? HOT 1
- Talk + Discussion: Presenting a decoupled NodeJS application and discussing about tradeoffs of approaches HOT 3
- Parser generators for developers in a hurry HOT 5
- Proposal talk: Frontend test HOT 13
- Lightning talk around feedbacks HOT 5
- Mini Unconference HOT 1
- When to use a library or framework
- Dojo on event-driven/reactive approaches
- Horizontal segregation and multi-disciplinary/cross-functional teams HOT 1
- Mob Programming on a TCR problem HOT 1
- TDD - How to really do it? HOT 6
- CI/CD - How to really do it? (NEXT)
- Agile
- Running open source projects HOT 1
- Microservice Patterns
- Let's talk about our failures (DONE) HOT 1
- How to write APIs that don't need versioning HOT 1
- Pair Programming - the good, the bad, the ugly HOT 5
- TDD Ping Pong HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from events.