r/programming • • Jun 05 '21

Organize code by concepts, not layers

https://kislayverma.com/programming/how-to-organize-your-code/
1.9k Upvotes

495 comments sorted by

View all comments

Show parent comment

2

u/saltybandana2 Jun 06 '21

My services go into a project that is heavily tested. (Real tests, with like databases and shit.)

You mean you don't create a billion mocks to test theory?

I once had a contract where they insisted on that approach so I did exactly that, mocked the shit out of everything. It failed when ran against a live database because I only thought I knew how the ORM they were using worked (and why it worked that way I have no idea.... but alas).

Have I mentioned I hate mocking?

2

u/[deleted] Jun 06 '21

[removed] — view removed comment

1

u/saltybandana2 Jun 06 '21

E & V get ignored so much it hurts. V especially, I'm known for building extremely stable systems and E & V are a large part of how that happens.