Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "code test"
-
Me: I need a Windows PC to test my code on.
Server dude: We don't have any free, but I can setup an old server for you.
Me: 🤔 .. I'll take it!18 -
Not a coding test, but:
Them: So you are interviewing for a programmer opening. Do you like programming?
Me: yes.
Them: do you make logos?
Me: ...I can...?
Them: good because you won't always be writing code here.
Me: I'm out.8 -
Project handover:
"Mmh okay, so what about test coverage?"
Dev: "zero"
Team taking the project "why???"
Dev: "You don't need test if you write perfect code"
Silence in the room... Followed by awkward laugh.18 -
We must develop and test our code
...via VirtualBox...
...running Windows XP...
...using IE...
..with vanilla Javascript...
...help me...19 -
Write a small js function using setInterval to fire a request every second ... then copy paste the code 450 times (literally, not an exaggeration) into a massive file to create a load test script.
This load test script also had no means to gather metrics or test response times or anything useful. It was literally a “did the server crash” test.9 -
HOLY FUCK I DID IT
I wrote an Arduino code for my friend. I didn't have any board at the moment to test it, but he flashed it the next day, and EVERYTHING FUCKING WORKED!!! AT THE FIRST TIME!!!10 -
Passed the online test.
Passed the technical interview.
Need to pass the final interview.
I'm applying to this company as a JS developer (backend). Their engineers are amazing and the fucking have 99.94% coverage on their test suiteeee; that gave me a code-boner.
If I get this job I'll finally say good bye to fucking PHPShit and Zend Framefuck and all this hacked bootstrap and 15k LoC "core.css/js"
I CAN DO IT10 -
Worst bad practice..
Manager: I need code today
Developer (thinking) : let me give it without unit test. Anyways tester will test it.
Manager to tester: complete testing fast.
Tester(thinking): developer must have unit tested it. Let me skip it.
Enjoy testing completed.
God help clients.. 😊5 -
Today I got my programming test back. 50/50 points. I only deserved 40 of them, since I wrote horrible code, so I told the teacher "I don't understand my points." His reply: "I also don't understand." I was laughing for at least 5 minutes 😂8
-
Spent my entire evening figuring something out (I'm new to this) and finally found a possible solution.
Got ready for writing test code, very excited...... aaaaaaand noticed its past 11pm so I've got to go to bed because work tomorrow
😥😭19 -
My dad said if I fix his old car then I can have it once I pass my driving test. I can't seem to find the source code...18
-
Me: Listen dude, the code worked perfectly and all the test cases passed so I'm done here.
Also me: What is this? What the fuck is this? Why does this work? What witchcraft is this?
*Screams internally*1 -
"So you need access to the test server?"
Me:"Yes"
"Please fill these 800000000 forms,sign here,get your blood sample,your ID ,your right kidney,letter of approval from your boss,...."
Fuuuuuuuck!!!! I just want to change only 3 lines of code!!!!!!5 -
QA: did you test the app first?
Dev: Yes, I test all my code all the time.
*QA crashes the app within first 5 seconds.*4 -
When your boss wants to try out the program but you didn't have enough time to test the code, so you are just sitting there like1
-
Remember those innocent looking two lines of code that you didn't write a test case for, because they can't possible break, right? Well, they are going to fuck you up.3
-
"Your resumé looks really good. We would really like to hire you. But you need to do this completly job unrelated test/coding challenge first."
----
"Is the test Android related?"
"Yes"
*Opens Test* -> "what ist the complexity of this function (written in c)"
*Scrolls*
"Implement algorithm xyz in Go lang"
*Closes test and breaks something*
----
"You will need to Code on a small Android projekt so we can see how you work"
"OK, how much time will i need to plan for it?"
"Our lead dev decided to make it small so its only 4-5 days."
----
What is it with all this stupid hiring test these days? And what do these recruiter think?8 -
When you're looking at your cowerker's code and find a comment :
# Sam, Adam FUCK YOUUUU
Actually Sam is the PM and Adam is the test guy ...1 -
I found an interesting job post on SO, I decide to apply. It comes with a programming test. A simple unit test that must pass (see current-1 post). I get it passing, go to send off my resume and code and the fucking email they supplied isn't valid or active. Fuck you. Eat dicks. Useless fucking HR.
-
Team says their code is done, tested, and working. They have merged all of their code and now to merge it with mine.
Take care of the merge, go to test it, and NONE OF IT WORKS.
Ok... So maybe something in my code did it. NOPE. Still crashes without mine.
Thank goodness for version control.
Now need to help define what "tested and working" means...4 -
That feeling when you wrote alot of code, without being able to test it.. And then when you put it into the project, it just works!5
-
> Writing some code 😀
> Compile it
> 10 errors 😣😣
> Debugging mode on😎
> Write about 100 print statements to debug the code
> At last found errors and now remove those print statements😅
> Compile code
> 2 out of 30 test cases pass😤😤
> Exhausted and angry😡
> Silicon valley new episode arrives🎉
> Super excited after watching the episode and think like you too can code like Richard Henricks😎😎
> Coming back to the old code and build logic from scratch
> Compile and finally all test cases pass
> Task completed😂😂3 -
No matter how much product owners claim "bugs have priority over anything else", "we value high quality structured code", and "we do test driven development"...
...Once a big client wants a feature to be developed before they sign up, dirty code will be written from napkin specs, and that code will always be refractored "soon".4 -
I have never written a single unit test in my life. Hence my code breaks from time to time. Karma is a bitch 🤣3
-
Developer superstition, never say something is easy, fast or straightfoward.
It will take weeks to develop, months to test and debug and you will consider change jobs just to stay away of that code8 -
I saw one guy in Office writing unit test cases and documentation for his code .
Such a psychopath!!!9 -
Just tested my GPU code vs my non-GPU code.
Its a simple game of life implementation. My test is on a 80 x 40 grid running for 100,000 cycles.
The normal code took 117 seconds.
The CUDA code took 2 seconds.
Holy fuck this is terrifying.3 -
FUCK THE RECRUITERS WHO ASK US TO MAKE AN ENTIRE PROJECT AS A CODE TEST.
Oh you need to scrape this website and then store the data in some DB. Apply sentimental analysis on the data set. On the UI, the user should be able to search the fields that were scraped from the website. Upon clicking it should consume a REST API which you have to create as well. Oh and also deploy it somewhere... Oh I almost forgot, make the UI look good. If you could submit it in one week, we will move towards further rounds if we find you fit enough.
YOU KNOW WHAT, FUCK YOU!
I can apply to 10 others companies in one week and get hired in half the effort than making this whole project for you which you are going to use it on your website YOU SADIST MOTHERFUCK
I CURSE YOUR COMPANY WITH THE ETERNITY OF JS CALLBACK HELL 😡😤😣9 -
I am like the weakest programmer at my job. I wanna improve and get better. Understanding how to write good unit test to reading code. Damn it. I just wanna be better.9
-
My co-worker not only doesn't create unit tests, he comment out my own unit tests after he changes the code and the test breaks.11
-
After running tests, code review, coverage test ... And your application crashes in the middle of a demo in front of your PM and your coworkers.
Coworkers : "When you try your best but you don't succeed ..." (Coldplay song)
PM : DAMN SON! WHERE'D FIND THIS ?4 -
Do you guys know any Github repos with really Bad C++ code?
Just wanna see if I can understand it, as a test... 🤔9 -
I have to refactor code from an intern. He's VERY lucky that he already left the company.
If I'd say he programms like the first human that would be very insulting to that first human.
It looks like code at first sight, but when you try to understand what he was doing to achieve his goal you get a brainfuck. Duplicate code, unused code, dumb variable names like blRszN.
He wrote unittests like "expects Exception to be thrown or Server returns Statuscode 500".
Yes, Exception, the generic one.
THESE FUCKING TESTS ARE GREEN BECAUSE YOU DID NOT ACTUALLY TEST SOMETHING.
GREEN IN THIS CONTEXT MEANS: YOUR PRODUCTION CODE IS A BIG PILE OF SHIT.
I already removed 2 bugs in a test which caused another exception than the "expected" one and the test does still not reach the actual method under test.
Dumb fucktard.
The sad thing: The fuckers who did the code reviews and let this shit pass are still here writing code.4 -
Me: *rewrites chunk of code*
"Time to test this baby. This is gonna fail spectacularly"
Code: *works*
Me: "Fuck!"5 -
We have a developer position open in our APAC office.
Before I take phone interviews, we ask candidates to complete a preliminary code test.
I’ve just been sent an email with code attached in screenshots...
nope.8 -
Actually be encouraged to test code and play with it to understand the inner workings and gain some experience.1
-
When you gotta refer docs, write code and Test mulitplayer........you need the squad!
Working on implementig mulitplayer for my game!7 -
In a test software that I'm working on, there is a variable at the very beginning which has a comment "Don't change this variable!".
Hidden within the code is function to check the value. If the test user change it, a giant ಠ_ಠ appears on the screen.
No one will complain, but I can hear the gasps and the sudden chair movements... 😈1 -
When you test your backend code thoroughly before pushing to production, but a fatal exception with the much larger production userbase causes one of your vital threads to die with a NullPointerException.6
-
Tl:dr
Our post offices now test E-Voting and give 50'000CHF to the first one who manipulates the Voting system, on Gitlab, A guy named "FuckThePost" made the Source Code public.
Love that guy...10 -
Rant!!
Fuuuuuuuuuuccccccckk this new dev hired is such a dick he keeps on not testing his own code for simple things and expects everyone else to test it on local and tell him his bugs.6 -
My first new year resolution for this 2017 is learn to do the f****ng unit test before implement the code3
-
What do you need a boss if you can find the idea, analyze it, design the product, code it, test it, setup the cloud and even do the marketing.
Dear bosses,
I am a developer not a God!3 -
Just implemented a design from a UI/UX designer in code. Works perfectly on iOS, now to test on android.2
-
"I couldn't fix the test so I commented it out."
"I removed build timeouts because our jobs started taking that long."
Next I'm waiting for "Compiling the code is good enough we don't need tests" before I lose it...1 -
This junior dev is killing me with all of the bugs in the code ... like did you even test it to see if it works fml1
-
Germany trying to fight Covid with digital tools (at least not another app today): registered for a test with QR-Code, Webform and E-Mail. After being tested by friendly people, I received an email that contains a link to a download of a PDF document.
Inside the PDF, a QR code, and a bureaucratic text like during the time of the Prussian emperor: "Bescheinigung über das Vorliegen eines positiven oder negativen Tests (Antigen Schnelltest) zum Nachweis des SARS-CoV-2 Virus".
Okay, we have a national "Corona Warn App" using Google's bluetooth based distancing detection, that also allows to add a test by scanning a QR code.
Scanned the code, got
"QR code is invalid".
Despite the unfriendly UX writing and the unhelpful description, another proof of the state of digitalization in Germany in 2021.
I am not even surprised.
At least my test result is negative.11 -
So I wrote code to show the FUNCTIONALITY of my module , which has temporary variables and temporary code.
Boss after verifying : so it's done right ?
Me: no the code needs to be written .
Boss : but it's working...
Me : yeah , but this is a test environment , I need to put everything in place and test .
Boss : so it'll be done in 15 minutes right ?
Me : ...
Boss: ... -
TFW you’ve been trying to debug an issue for over an hour and you find out you typed:
variable1 == variable2
Instead of
variable1 = variable2
AARRGGHHHHJJHHHHHRIFNRIDKEJXJDJ!!!!!!!9 -
First comment by the architects that were reviewing my test, as part of the selection process:
"Well the code was very well documented, not something we see much of..."
Made my day :) -
Yes!!! Only took one morning.... (changed the Downloader from WebClient to Selenium to get past the bot check, cant find old rant)
Good test for new PC other than games I guess... I can code and compile my projects.9 -
You know you have a quality teacher for C code when you are writing a test and you have to write the code on a piece of paper4
-
*Writes code, doesn’t test* “Ah this works, I’ve done it before”
*Finishes project, runs test, errors everywhere* “FUCK!”
I do it on non-important projects... but I need to stop before I start doing it on important projects 😑2 -
Modern HR is great. I love the fact that my future as a developer depends on how effectively I can talk over someone and create solutions to shitey ice breaker games.
Fuck off. Code test me, cunt.1 -
I hate these idiots that post source code examples as an image just so they can keep their cool highlighting and style. How the fuck am I supposed to test that without re-typing the whole thing myself? Ever try OCR on source code? Not too great, is it.12
-
Today I was writing Selenium tests and was struggling to find a good way to test a text editor. We did a weekly code review and my team lead rewrote the test ij 10 lines to generically handle all cases.
Hopefully I'll be a good dev someday. 😔4 -
One of my colleges complained that the remote vm he uses to test his Java-Code is so slow that he thinks it's actually just a potatoe.
I said to him... Well you know... 3 Billion Devices run Java.2 -
I feel so bad for the Devs of this app, they can't make up bullshit excuses and not bug test their code like other Devs can
-
I really like this book on the basis of the philosophy overall, no this doesn’t solve all problems but it’s a good baseline of “guidelines/rules” to program by. Good metrics or goals to architect and design software projects high and low level projects.
Fight Software Rot
Avoid duplicate code
Write Flexible, dynamic, adaptable code
Not cargo cult programming and programming by coincidence.
Make robust code, contracts/asserts/exceptions
Test, Test, and TEST again and Continue testing.. this is a big one.. not so much meaning TDD.. but just testing in general never stop trying to break your software.. FIND the bugs.. you should want to find your bugs. Even after releasing code the field continue testing.24 -
small victories... leaving little fuck you notes all over the code..
along with all the test cunts that still get incremented on the production.. -
This isn't a rant. This is a brag on my team.
I asked the team what exactly a feature did. They read me the test code.
I may get a little weepy. So proud. -
When you test/debug every piece of code you made/changed and then find out the rest wasn't working as it should.. FML
Test everything, trust noone!!!!!!
Rewrite all!!2 -
We actually had a small "code on paper" test (more like a recap test) yesterday, but we didn't have to write much rather than just have a basic understanding how classes and instances of those work. It was like 6 small lines of code to insert. I don't mind coding on paper as long as you don't have to write a big program with it as a 1-hour test.2
-
When you encounter a bug in your code while writing a test and you have absolutely no idea what's wrong...
...and then you see it's a type problem. -
Was writing a functional test in AdonisJS that queries an API endpoint with data and my test stays red with a dainty `expected 500 to equal 200` assertion failure.
In frustration, I yelled "What must I fuchen do to get my 500 to become a 200". Then my dev friend, an absolute fuchen genius tells me, "Subtract 300." I hope the prat stays debugging his code for a week!!8 -
Ugh all but one unit test is passing :-(. I know the code is working- so the problem must be in the test... [add @ignore to test]. Yay they all pass now!1
-
Yet another day at work:
My job is to write test libraries for web services and test others code. Yes I know to code, and have a niche in software testing.
Sometimes developers (whose code I find bugs in) get so defensive and scream in emails and meetings if I point out an issue in their code.
Today, when I pointed a bug in his repo, a developer questioned me in an email asking if I even understood his code, and as a tester I shouldn’t look at his code and only blackbox test it.
I wish I can educate the defensive developer that sometimes, it’s okay to make mistakes and be corrected. That’s how we deliver services that doesn’t suck in production.10 -
After a long time I finally reached this milestone of 100% code coverage. I often asked myself why I had to test every function, no matter how small. But this log output of 100% was worth it.3
-
for ( let i = 0 ; i < Number.MAX_SAFE_INTEGER ; i++ ) {
console.log("I will never write code before writing test again in my life 😭😭")
}5 -
The "unit" in unit test does not mean your ENTIRE APPLICATION. Ever heard of scope!?
I am amazed how often people write overblown test setups, mock hundreds of unrelated services, just to test one tiny bit of logic.
That bit of logic could have been a pure function.
For that pure function you could write a dead simple unit test. Given that input, I expect that output. Nothing more, nothing less. (It helps even more if the pure functions only accepts primitives, like string and numbers, or very simple immutable value objects).
No I don't care that the service is used by another service, as your mocked interaction also doesn't test the service as a whole but you just assume the happy case most of the time anyway. You want to test the entire application? Let's not use unit tests for that but let's use a different kind of test for that (integration test, functional tests, e2e-tests).
If you write code in a way that easily allows for unit testing, your need to mock goes away.rant unit tests test all the things tests you are doing it wrong tdd testing don't mock me unit test1 -
a lesson that I learned the hard way: Don't test a code or a library on your master branche, in other words: don't shit where you eat.3
-
MOCHA YOU FUCKING BITCH, THERE IS A DONE() CALLBACK BEING CALLED IN THIS TEST, WHAT IS YOUR PROBLEM??? I WILL RAPE YOUR FUCKING SOURCE CODE. But really mocha test, why u no work so we can both move on with our lives 😣😦😞7
-
I have to fix a memory leaks of two jest test files of
2 FUCKING THOUSAND
lines of code each.
The End.15 -
*has a test in school on html and javascript*
*Studies a lot and checks to see if code works*
*it works*
*goes into test confident*
*None of the Javascript works* (legit nothing)
Kill me6 -
There are devs who are chill. Then there's me. Deadlines give me anxiety. Being responsible for the code I didn't write and being blamed for the bugs I inherited stress me out.3
-
BANE OF MY FUCKING EXISTENCE. STOP POLLUTING MY PRODUCTION CODE WITH TEST CODE, YOU FUCKING CRETINS.
-
When you spend 2 days writing ~1500 lines of code and you finally put everything to the test and nothing works properly, FML :/1
-
This fucking guy create a mess of a code, more than a spaghetti code, a clusterfuck of shit untested spaghetti code, and the project is actually getting well, our customer is getting bigger but everytime there is something to be added, its a fucking pain to add, and when something breaks, almost every thin breaks, and the shitty guy who wrote this code is quitting and its fucking up to me to clean up all the fucking mess, fucking asshole.
DOCUMENT AND TEST YOUR CODE KID, DONT BE A FUCKING SPAGHETTI PROGRAMMER7 -
Passed a code test for once and invited to interview with engineers.
I’m nervous yet proud. Any tips? It’s the first time I’ve reached this point5 -
Virtual box.
I recently had to code sign an app for ios without having a mac at the office or an iphone to test it on. Thank god for virtual machines though1 -
So this is what a test looks like here in my school...
I really like my teacher but his test are... uhh... fucking awful.
I mean the code isn't even indented ffs! Like wtf?!? How should one be able to read this bullshit?
The questions are shitty too.
Also please add line numbers so it is easier to describe how things work in the code.
AND USE FUCKING A4 PAPERS FFS!!!
Thanks,
an experienced student7 -
Just looked at a fellow devs code (has 4 years experience). His test rig has the same 5 lines of code, copy pasted in the same file ... 400+ times.
What is the appropriate action to take?8 -
the web developer equivalent of waiting for code to compile is waiting for your local test DB to be populated with recent data from the production DB2
-
Don't you love working out a piece of code in your head that's been troubling you for ages but you can't test it because your at work... It's horrible.
Tempted to whip out vs code and just quickly test my theory in JS...2 -
If your “solution” fixes the test case which is failing, it does NOT guarantee that it is the correct fix. You don’t just blindly change whatever piece of code you like to make just the test case pass. You actually also need to analyse the code and ensure that the rest of the intended functionality is still intact.3
-
The way I was told to write unit tests was particularly terrible.
No mocking of objects or dependencies so the tests ran the actual code in full including updating databases and files. Then at the end of each test there was code to restore all changes back to before the test.
Each test ended up being over 100 lines. Madness.1 -
I solved this bug today just to get good sleep at night by not brainstorming every solution.
Here I am thinking about the different scenarios to test my code!!I think I'll sleep peacefully tomorrow!! -
That awesome moment when your code passes all the test cases 😁
Anyone else likes competitive coding??1 -
Today's interview not went well. Shit, that company instead of paying other online talent test sites, they have their own version. Horrible experience, I never type code in text box.
Worst experience 😣1 -
The most shittiest feeling in competitive programming is when your code passes all the test cases except the last three. 🤓😌2
-
Cocktail for disaster:
- TDD
- Mocking
- Multithreading
- Averagely well written, testable code
- All tests pass
- One test methods still shows some vague stacktrace in a worker thread ❌ but the test passes ✅
- Run only that test method and no stacktrace.
So I've been pulling my hair for the last two days trying to figure out what was throwing in that test method. Turns out that thanks to the multithreading going on, some other, similar method threw the exception in parallel. And apparently a different test method was already running when the exception was finally caught.
🖕
When I discovered that, it was fixed in a minute. 😭1 -
Fuck my project manager. He wants to sacrifice code quality, test coverage and technical debt in favor of more features. In the future when everything takes longer or breaks guess who is responsible? Certainly not him.3
-
Hmm. This code needs refactoring.
*recodes on Local and uploads*
Works on my branch.
*git push origin master and merge*
Works on Dev.
*deploy to Test*
Works on Test.
*deploy to Live*
Doesn't work.
*compares Live to Test, Dev, and Local*
No f$@%^%%$# difference!?!!
*quits development and lives under a bridge*5 -
The chances of you becoming a criminal increases when the QA says, "your code ain't working" and you notice he didn't test the right branch.
-
So today I published my very first VS Code extension! 😁 I don't think anyone but me will think it's useful but it saves me a few seconds every time I change something in my code and I want to test it. Just hit a button in VS Code an and ta da! The project is compiled and running!
VS Code Marketplace: https://marketplace.visualstudio.com/...
GitHub: https://github.com/olback/...3 -
dat feeling when you code a chunk of a page for 15mins and then you test it for an hour and a half cause you cant believe there's no bug or unhandled error
-
I'm looking for a kind of "lorem ipsum" but not for text, for code. Some kind of random code generator with configurable language to test code rendering, compare programming fonts, etc. Any suggestions?8
-
"Manual testing is often quick and easy and satisfying – you can directly test your application, one can see the results immediately on your screen, and one can interact with the application “for real”, instead of in the sometimes-awkward scripted/mocked mode of unit tests. It’s a very natural instinct.
However, it’s also largely-wasted effort! A manual test only verifies the current state of the code base. As soon as you make a change, you’ve started to invalidate the results. If, however, you take the effort to encode the test in code as an automated test, it continues to be valid indefinitely into the future."
https://blog.nelhage.com/2016/12/... -
most memorable bug I fixed
Line 1:
- throw new Error(‘test’)
+ // throw new Error(‘test’)
yes, this was committed code in production4 -
Developer just emailed our team a complaint that our logging assembly was resulting in their poor test coverage and they sent a change request to give them the ability to mock the underlying log provider (ex. from the event log to ‘something else’).
Looked at their tests, and they are testing whether or not the .Log was executed (on an exception, if the .Log method was not executed, the test failed), which seemed a bit worthless because we’ve already got coverage in our unit tests.
We had a meeting to discuss the issue.
Me: “I’m OK with changing the logging code if it’s necessary, but I want to understand why.”
DevA: “Logging errors is crucial to the database transaction. If someone removes the logging, the tests should fail.”
Me: “If someone removes the error logging on purpose, then they likely have an agenda and will remove the test validation too. It wouldn’t be an accident.”
DevA: “That’s not my problem. They will have to deal with HR.”
Me: “We purposely prevented someone from intercepting the logging just for that purpose. Your test code already covers the business rule, testing the logging seems out of place. That would like writing a test to make sure the System.IO.File.ReadAllText actually reads all the text from a file. You kinda assume a few smart Microsoft engineers already wrote tests for that.”
DevA: “Yea, I guess that would be silly.”
Got cc’ed an email a little bit ago from DevA to his boss..
“We’re not going to be able to change logging assembly. This may have some impact on our overall test coverage as those lines of code will not get testing coverage. You will have to let the DevMgr know we will not meet our test coverage goals.”
WTF!1 -
Not writing tests for your code is like leaving it unguided in the hands of future Devs who gonna just change something and break the core logic and there won't be any regression test to run and check the integrity.
-
Optimization issue pops out with one of our queries.
> Team leader: You need to do this and that, it's a thing you know NOTHING about but don't worry, the DBA already performed all the preliminary analysis, it's tested and it should work. Just change these 2 lines of code and we're good to go
> ffwd 2 days, ticket gets sent back, it's not working
> Team leader: YOU WERE SUPPOSED TO TEST IT YOUR CHANGE IS NOT WORKING
> IHateForALiving: try it on our production machine and you'll see the exact same error, it's been there for years
> Team leader: BUT YOU WERE SUPPOSED TO TEST IT
Just so we're clear, when I perform a change in the code, I test the changes I made. I don't know in which universe I should be held accountable for tards breaking features 10 years ago, but you can't seriously expect me to test the whole fucking software from scratch every time I add an index to the db.1 -
Started a new job as junior developer. One of my first task was to sent a simple notification on an event in out product. Write the code, test that it works, push to devops.
Code compiles, tests pass, it’s deployed to internal test env. Check that my notification works in the test env. No problem.
It’s deployed to the customers test environment. It works and customer accepts it for prod.
We release to prod and of course it fails. Seems to be a simple string.Format that fails for god knows why. After 3h of debugging on prod without success we decide to roll it back.
Today we decided to try it on a backup of the prod db since one of the strings was taken from the db. Still working. No matter what data I input when trying it locally it still wont reproduce the issue we saw on prod.
Fuck this6 -
If I had a nickel every time the unit tests failed not because something was wrong in the code, but because someone had messed up the unit test I'd be able to retire early.
I just spent the better part of 10 hours hunting down a bug in some production code only for the test to be wrong because the person who wrote it had mocked the http response incorrectly.
Nothing I did to "fix" the code worked, because nothing was wrong with it...4 -
When you have to edit a 100+ line method but you discover that it has 0 test coverage.
Feels bad :/5 -
Functional test are failing.
Expected: 7109
Got: 9000
Grep code-base for 7109. No findings. 0_o
Dig through test setup written by a drunk.
Find:
assert(actualPrice === 1800 * conversionRate)
Goddamnit. You shall not calculate your expected values in a test setup.1 -
I've got staff, I've got staff
And they bill time and a half;
Now I only write the gist you see
And they can code the rest
Open source, Fraying nerves
Smoothing out regression curves;
Try this framework, it's ambitious
It was made of spit and wishes.
Coffee rings, at first glance
But of course miss, he's freelance;
And this code base is a truly scary mess
I can't expand the menu
Even chance its home brew, unit test;
Unit test, unit test!1 -
Fucking fuck sonarcloud and everything about it. Part of the build pipeline for us to deploy code is to ensure that 90% of the code is covered by a unit test. Great in theory, horrible in practice. You think you've written enough tests that actually add value and test a valid piece of functionality but NO, sonarcloud throws a fucking fit because you're at 89.888 then your branch is going nowhere. Because everyone else gets to this stage and writes just enough tests to get the coverage to 90.01% then it becomes a stand off of who will break first; the code coverage threshold or your mental state.4
-
I would rather go through a burning building than doing a single line of code that is for test automation in Salesforce. Salesforce is the biggest sin of humanity.12
-
When you wonder why it doesn’t work put print statements all over the code, because you want to find the error, but no print Statement works even if it just should print test...
Fml4 -
quotes of best times
"You would never have a bug if you don't write a code"
"Your code could never crash if you don't run it"
"Your program can never fail if you don't test it"
"Your startup could never be unsuccessful if you don't deploy"4 -
Fixed a high priority bug today just prior to release. There was 100% test coverage. The tests pass both before and after the change. The product behavior is correct now where it wasn't before. Just one more reminder that test coverage does not equate to either quality or correctness. Tests are alarms (at best), and quality of tests are no better an any chunk of code. All tests have costs, but not all have value. All reasons why I am skeptical of the value of code coverage, TDD, or anything that posits that "all tests are good".6
-
That moment you write and test HTML code on your phone in a metro bus and a brother looks at you like you're from the future
-
I am the unit test guy now, please send all of your untested and poorly thought out code my way to be tested4
-
TEST, TEST AND TEST ASSHOLE
OUR PROJECT IS GETTING BIGGER AND START TEST YOUR FUCKING CODE SO I DONT HAVE TO CLEAN UP THE WHOLE FUCKING MESS
FUCKERS2 -
That feeling when your newly added calculation module now has 93% code coverage in unit tests, with the client working on a test case for the last bit.2
-
When you are finally gaining some momentum after ironing out some crucial flaws on your pseudocode, ready to code and test, but then a wild meeting suddenly appears!1
-
Trying to refactor legacy code can be a real adventure. It's like exploring an ancient ruin, except instead of hidden treasures, you're uncovering cryptic code and dead ends. But the real plot twist comes when you realize there are no unit tests to guide you. It's like trying to navigate a maze blindfolded - you never know when you're going to hit a dead end and end up with a headache! 🤯6
-
Are there people here who actually unit/integration/end-to-end/stress test (almost) everything? Or is it a common fact that nobody has time/budget and/or needs to do so?
I like to think I test all the code I write, but to be honest, I think it's closer to 1 to 5%4 -
Live deployment next week Monday but Product Owner really need this new fix in.
Can you code, push to test, test it, push to acceptance test, UAT it before Friday...
It's Wednesday today 😐
Project manager says ok 😱1 -
You're not a real dev unless you've made so many changes in your code without testing, that you're too afraid to actually test it.4
-
So our Chief Test Engineer left the company because of overwhelming frustration and stress. We working on new stuffs so we test our partly done product with partly done test tool developed be another of our team. His successor started to drop most of the 3rd party tools and workflows and documentations to trash expect this one unfinished test software.
Now he wants that we add more features to this software so it can replace everything he trashed already: run tests, generate test reports, generate documentations and so on.
On top of that he organized a workshop to read all this software's source code together, understand how it's works so we can rewrite the whole software from scratch.
WHAT?!1 -
I hate the jitsi_meet package, so I decided to fix the bug myself instead of waiting for the code owner to fix it. I forked it and pulled requested the updates. All they have to do is review, test the updates and merge the code if there's no error.
And the fucking problem was wrong data type, old version of Kotlin was used, and was android embedding V1 instead of V2. Solved by a "little" adjustment of the code. I wonder do they test the code before publishing their packages?
For those who are stuck on the issue, you are welcome. Now you have the solution.
Refer: https://github.com/gunschu/...1 -
I'm so sick of "senior/lead" developers pretending they know how to write tests and ending up with these unmaintainable test suites, full of repetitions and incomprehensible assertions.
You should take some time to learn from your mistakes instead of just continuing to write the same shitty tests as usual!!!
Every time I arrive at a new team I spend weeks just trying to understand the test suites for what should be fairly SIMPLE applications!
UNIT TESTS SHOULD TEST UNITS OF CODE!
If your unit test tests seem to be repetitive, they are not unit tests. Repetition is expected in integration tests, but that is why those are usually DATA DRIVEN tests!!!14 -
FML having to take on and support a python test framework that looks like it was written by a junior C embedded dev without a mentor.
- Imports everywhere in the code
- No abstraction or OOP
- sys.path.append fest (broken imports of course)
- Global variables fest
- No docstrings
- No readme
- Somehow mixed with a jUnit test framework as well
- Uses Windows environment variables profusely
- Pycharm has a stroke when I open files from this project5 -
ticket sized small: figure out why this thing is failing, get the old MR to work, test it
month old MR, over 8000 lines of code changes
FML5 -
This is really annoying. My single manual test takes 10 minutes to run. Can't blame the task because its big, can't blame me, code optimization is not necessary and won't speed anything up. So here writing a rant waiting for it to finish1
-
Friday afternoon 5:00pm: everything works wonderfully fine, let's go home!!
Monday morning 9:30am: Let's do some more test on the latest code I have wr.... KABOOOOM!!! -
Me : Hey, can we add datas in the database so we can test every single possible situation with it ?
Worker : Nah, it's better that you don't touch it, lemme do it.
*Later*
Worker : Hey I've added data to test our code.
Me : *fetch data, see only three similar objects that fits in only a situation, I can't test the others" Thank you, that was really helpful.1 -
So apparently Skype has a code editor for interviews.
Would you use this tool?
Source: https://techcrunch.com/2017/08/...8 -
Me: Where is your unit tests?
Dev: I tested manually and it worked.
Me: What if there are changes to the code in future?
Dev: We'll manually retest the implementation. It'll be fine.
*flip table*1 -
Today, I found this in our upstream repo. How the fuck does it even get merged?
No use of tempfile, instead of idiomatic it's idiotic. I have changed that system, now I am hoping i don't have to refactor thia shit.11 -
This is just a sweet little harmless block of code, why should I unit test it?
3 months later...
Bug in production : This is why. -
If you're reviewing someone's code, do you run/test the code before reviewing the logic? Or do you review logic before running the code?4
-
When there is no way to test the code you have written.... I cannot help but stress my arse off...4
-
Looks familiar?
I really need to start giving more descriptive names when I test code..
Var that=
Vat thatt=
Var thattt=
....
Func workFFS=4 -
php is so fucking great, every time I'm coding in php I'm astonished by the speed it goes from code to test. Unfortunately its the only benefit I see in using php.2
-
Dev: [does some weird code to make test pass]
Me: this won't work. Literally the documentation says what you did won't work once we move towards our end goal architecture.
Dev: [shows middle finger and requests merge and somehow managed to get code merged]
.... One Sprint later nothing works...
Dev: [does some weird code to make test pass]
Me: no. You need to solve underlying problem.
Dev: [shows middle finger and requests merge and somehow managed to get code merged]
.... One Sprint later nothing works...
Me: please stahp
Dev: [shows middle finger and requests merge and somehow managed to get code merged]
Me: WTF man do your fucking job
Scrum Master: stahp lowering our velocity
Me: wut? 😒2 -
Favorite memories by far were the foosball, beer, ping pong, and subtitled foreign movies while we waited for code to deploy to test environments.
-
Mini witch hunt going on with broken builds last couple of weeks. Change satellite assembly/project A, breaks random unit test that hasn’t been changed for months and the TFS nazi sends out emails demanding the “broken” projects be fixed. Doesn’t matter the unit/integration tests are likely out dated and team responsible for the tests needs to fix it.
Yesterday I deleted some logging code out of a security assembly, broke an integration test that hasn’t needed to be ran since January (test database didn’t exist anymore).
I would have had to re-create the database, re-import the test data (not trivial), re-deploy a service using the test database…blah. All because I removed some logging code.
I deleted the gated check-in TFS build definition. Code check in … no sirens …whew! I win! -
Chrome likes to count teleporting goats, Android tests if the user is a monkey. I like to put "void fish(object look)" in my code and throw the fish where ever I wanna test something.
What are some interesting functions you've added to your code? Has another dev caught your function yet? (mine hasn't been caught yet, yay!)3 -
FML when the code that runs every 10 minutes to check and bill a customer keeps charging him and the logs are terrible plus you have no idea what the issue was so you have to push production code to test and fix.
-
When someone writes a JUnit test that passes, when the code is completely wrong. I hate group work.1
-
Tfw when you wake up, realize the interview question code you submitted was broken, check the provided test cases, they don't catch your logic error, so you write back with a breaking test case and an outline of the bug fix. Got the onsite...1
-
Colleague wrote all his test cases after finishing his code and set expectedOutput to garbage. His tests failed, printing actualOutput. Then he just replaced the garbage expectedOutput with actualOutput. Bingo bango, all tests passed.
"How do you like me now TDD?"1 -
Trying to convince the class that test-driven development + DTSTTMPW ("do the simplest thing that might possibly work") + pair programming is the way to go, our software dev prof had us split in groups of two that would each get a turn to
1. add a unit test
2. edit the code so it passes the test
3. commit the change
The goal was to write a java class that converts integers to roman numerals.
Each group had only 2 minutes before the prof made them revert their changes.
After 45 minutes the code was just 10 lines of this:
if ( n == 1 )
return "I";
else if ( n == 2 )
return "II";
else if ( n == 3 ) ... -
Always test your code, especially if you did a commit to master on Friday afternoon. Otherwise, you will end up deleting thousands of vms.
-
Web code editors are shit for interviews!!
I was given a timed interview test to code on a hackerearth’s code editor. First of all I have never used hackerearth’s code editor because they suck. The problem was very simple and I cleared the round anyways when an actual human saw my code. But my point is why are programmers creating shit editors for other programmers in a timed environment. I couldn’t figure out for the life of me how the fuck I should take an input and output that in this shit editor. The code logic was ready but the test cases failed.
So Should I be learning about hackerearth’s shit code editor in an interview with a timer or should I be judged on the code logic in the specified time?
I seriously find these web code editors most of them annoying. Cause they aint good enough. You need time figuring out the tools first and then code the logic.
Usually in your job you’re gonna use the editor of your choice. Not a fucking shit fucked half arsed hackerearth code editor. My rant is for those of you if you’re taking interviews on such platforms, be there. Don’t rely on those platforms. This automated crap is still crap.4 -
Me to co-worker: The tests are failing because you didn't format your code before submitting your PR
-Co-worker changes the test command to run the format command just before running the tests-
Co-worker: The tests are passing now!
-facepalm- -
Remember folks, always test your code. Even if you're sure about your ideas there is something you haven't considered that fucks up everything driving you insane.
-
I see that many junior level programmers are being given fairly large take home programming test/projects. I think that if you interview someone and check out their git hub or discuss some code together you should not need to also do a take home test. You don't have good interviewing skills and are making your company look bad. I also think it is an incinerate way to waste a candidates time.1
-
What tools/pluggins do you recommend for:
VSCode
Data management.
Test code
Organization and collaboration
APIs
Debugging
And other tools you like to use the most? ✌🏻☺️2 -
I just reviewed a pull request with a test case like (pseudo code):
# Test MyService
const mock = createMock(myService.myMethod)
.whenCalledWith("foo")
.returns("bar");
assert(mock.myMethod("foo") === "bar"));
Why though? Why are we testing the mock? What is happening here? This test has no reason of being there instead of a fuzzy feeling that we now have unit test to lure us into a false sense of security.
I asked why we don't do an integration test. Response was: "They are slow."
Well, duh, but at least they would actually test something.
What do you gain by asserting that the mock is working the way you set it up?3 -
My brain hurts from trying to figure out this unit testing crap. Is it just me or is it really a struggle to test your front-end code? I'm using jest and enzyme to test our React app but complicated parts of code with multiple state changes or calling props is making my life a living hell. I mean I usually just debug by console logging everything and it works lol...but my fucking boss has forced me into writing this unit testing crap. FML.7
-
Couple of weeks ago I received a negative response about a code test I did for a front and position. They only said I was not a good fit.
Today, I received another email from them, asking me to do a test. I asked for clarification, and they said they are giving me a chance to redo the test.
Sounds weird, but I'll redo the test anyway. The task is to code a responsive page that consume an api. I'm using vue, sass, git, modular and semantic code. What else should I focus?
The deadline is in 36h.1 -
So in my experience, coding while I'm not sober actually helps out sometimes. I always end up documenting my code way more so that I can keep track of what I am doing, and the code I write is actually decent.
Ofcourse, I always re-test it once sober again2 -
Ever written tons of code when drunk, pushing off testing for when ur sober?
Now sober and I realize I have 639 LOC to test - 27 functions
Cannot get myself to hit "run" :-/1 -
Love to ear the due date to a projecto ia for tomorrow and i have to code 3000+ linea of code and test it in one day...3
-
Every time we have a release, "Release Engineering" stops building our test environments from master. I've been preaching Continuous Deployment for months and here we are with the most broken system. The build actually builds all test environments AND prod from the same branch because "it's easier" for "Release Engineering". So now I have to wait for the code freeze on release and hope RE doesn't fuck up and deploy an untested branch to prod... AND hope we're given enough time to test and debug the next release since we can't right now...1
-
This is a group sin.
We'd get the code checked and then run it straight to live. No test environments no real back up in place or process for releasing.
Just run code in if it broke run fix 1 through 3 until you got it right. That was two years ago. -
Wanted to get to bed early tonight, but ended up wasting two hours after I moved code from my development machine over to a test system and it was failing. After adding all kinds of logging to figure out where it was failing on the test machine i realized i fixed am error in an input file on my dev machine, but that error in the input fine was still there on the test machine. Another night with little sleep and tomorrow is Monday. 😭
-
I’ve just received a Code test to make an entire game before Friday and I’m kinda sh**ting myself...12
-
Junior front end guy made a backend code, he made even a test.
GET /model/ very nice simple case tested.
NO. MORE. TESTS.
Well, it's the same guy who complained reaaaaally surprised that he had to check http status code after a request.
Im kinda the bad guy because I get upset with that stuff instead of clapping his stupidness2 -
That moment when you’re debugging, and you realize that your output files are not empty because your code isn’t working but because your code IS working... 😑
I changed the test files I was using so I wasn’t expecting that particular behavior. None of the input data met the requirements hence nothing was being written out. It wasn’t until I tried a larger test file that I realized my code was working.
A simple discussion with a teammate would have solved this. 👀😂 -
Write code ... test ... bug found ... solve ... retest ... works as charm ... going to commit the code ... last test ... 100 exception thrown
-
How my friends work day goes, I worked at the same firm and on the same project, I dont pity him.
70% debugging
25% refactoring - after his pull request was denied a few times, and had to rewrite that code in question a few time. I think most people go mad
3% test writing
2% code writing -
Working on an assignment in Java. Was making a test, but no matter how hard i tried the test would never run. Went through the code several times changing it entirely.
Realized after four hours that it was the test that was wrong, not the code 🙄1 -
My Office Sucks. They give me impossible deadlines, and never properly test my code. And when it breaks in the production, they blame me.5
-
A remote team decided to annoy me by trying to hold me accountable to their project plan timelines while not delivering a viable API. So, I code reviewed them.
NOT ONE FUCKING TEST! They are "meeting the date" and will "fix it later".
They beat me to production though.
No wonder they argued that a complicated, fragile, expensive, multi-product flow test was absolutely required.
I returned the escalation favor. -
Google codelab's logic :
"uncomment the code from a xyz function
run the test
test fails
uncomment the code from abc function
run the test again
test pass
Congratulations you learned test."
Well apparently this is not how world works Google 😥😌😴 -
Spent a whole morning trying to make a unit test work only to find out it didn't work because of duplicated code.... Fml
-
You all enjoying and excited being coding until someone asks you to test your code and care about code quality6
-
never code, never test anything, never even talk to clients. I just wanna open a software company, have Devs, designers, business people who do all the work so that i can get a lot of money5
-
I love it when someone wants you to troubleshoot an issue but will not give you a test user account to test with. So you have to sit with a user or talk with them over the phone while you troubleshoot. I'm literally elbows deep in the code and database, but you won't give me an account for security reasons. Ok, that makes complete sense.
-
sending in code every week into uni to get graded and every freaking time... my test cases are all green, and yet they manage to think of overcomplicated ~hidden~ test cases to fail me.. it'd be like: program a method that multiplies two numbers and return the result! so ill be like 'easy peasy lemon squeazy! return a*b; theyll be like 'yeah :D u got 40%' liKE wHAt do u Want from mE7
-
Dont you hate it when you're making something, and you all ready have millions of lines of code. Then when you go to test it, it breaks completely and it was just because of a mispelled word.
-
days ago i used to be very lazy about writing tests.. after forcing me doing it, I ended up being addicted to high line coverage... kind of satisfiying AF
-
After a massive refactoring of the DAO test aren't running after 6 hours of debugging and traceing I find what some "genius" left behind.He wrote direct database updates from the UI code. WTF? Who gave them git access?
-
Why? As a senior, you won't give some time to review my code, will let me merge my code to a branch, then blame us when it will produce the bug in production? why? 😐 Won't even arrange a code review/knowledge sharing session so that juniors can learn at least something. Even you won't encourage us write test cases. If seniors don't follow, are the juniors to blame? 🙂3
-
Have to do 80 hours of work in 40
*quits job, start at a new place*
Now I mostly wait for test and code reviews and are fucking bored...
Guess I have to start 100% freelancing soon 🙃3 -
I frigging hate unit testing an AngularJS application. The amount of mocks you need to create just to test a a piece of code is unbelievable1
-
Test studying tool. Load your questions and answers in a human-readable format. Take a test. Get summary of results. My pet project at the university, 98% of code is mine. http://gronostajo.github.io/drill2/3
-
Sometimes I'm so overconfident that I don't test some parts of the code I write and then curse myself when QE finds a bug1
-
When you test your code, it passes all 100 tests & still shits in the rehersals of a competition 😌 Only because I wrote a wrong if condition🔥
-
Collect project specifications & details.
- order by relevance.
List & install dependencies (possibly spin up a vm).
mkdir ~/Code/{lang}/{framework?}/{project}
Bootstrap skeleton & scaffold.
- ensure functional base.
Iterate specs list & create test case(s) one at a time, going: test => minimal to pass => refactor => next(repeat_cycle)1 -
Me: Writes tests while fixing bug
Supervisor: "I'd suggest fixing other bugs and then picking up test cases"
Well the reasons we have so many bugs is that you let our off-shore devs just write code with ZERO code coverage!! -
I really need to appreciate IE in so many ways. It let us to install other browsers, test crap JavaScript code and finally recommending customers to use IE to support their app.
-
Developer: “Fix this”
Developer: “You should test your code”
Developer: “You should rigorously test your code before pushing it to qa”
Intern: “it was working on my local machine ( shared my screen and showed him)”
Developer: “Do you test your code before deploying to qa?”
I’m fucking frustrated working 8-10 hours a day and listening to this condescending shit after making one mistake.
Now I’ve asked other developers and they think I was rude so tomorrow I have a 1:1 with my manager .
I’m just counting my days now.8 -
when I am maintaining someone elses code, the class is 900 lines and I loose the context on line 100... then I rely on the test fixture... where all tests are ignored.
-
Started with Codeforces. Some solutions in Python exceeded time limit at test #25. Wrote the same code in C++ but this time it exceeded time limit in test #33.
What’s the solution to this ? Replacing cin/cout with scanf/printf doesn’t seem to make much of a difference.6 -
I pushed some untested changes yesterday to my course team's code repo, and it broke one thing. Let that be a lesson to ALWAYS TEST CHANGES BEFORE PUSHING THEM! > _ <
-
Can't you understand this code is unmaintainable and doing a quick fix and also requiring of me to write unit test for it IS NOT POSSIBLE without a rewrite?! FML
-
Material-ui looks and complete and so but their documentation is a nightmare .
They seperated component example and the code of those example.You gotta go to one page to see a silder example and test it and then you have to click on a link at the bottom of the page to go to the code where they mixed multiple variation of this compoment into the same spaghetti code.11 -
Connecting local test server with live db for testing purposes. Needs 10 min to start up because much data is preloaded.
Checked against 0 instead of null in code. Big fat null pointer error greets. Another 10 mins lost. -
I hate unit test. I hate testing by code.
I hate the idea to write code that tests code. And that u must update both when u add a feature. Like wtf.
Good debug mode with clear verbose and precise reporting tool and voila.
Drives me nuts thus trending shit.10 -
When the services team asks the mobile team what the response on a request is... And then requests console logging on the app so that they can test their code.
-
When you don't know how to write test:
either you unit test the fuck out of system (couple test test to code) or you don't write anny -
Skipping jasmine tests- especially ones on partials (not the controller). Seriously, QA has automated test suites to test UI functionality. If it takes 30 mins to write the code and 3 hours to write the tests... it may just not be worth the effort when there already is automated testing.
Ugh I hate skipping them but you know how to test the UI? Use the UI. -
When you make a massive change to the code base and run the test suite to drive out functionality but nothing fails...
-
Need a workaround to start the application. Need to activate/deactivate a few workarounds at different points in the flow to test the code in development. Need a different workarounds to test the code in QA. Maybe another workaround for prod? Need a workaround to check in the code to CI/CD. Need a workaround to deploy the code.3
-
When the whole team started to work on the same project for the first time.
You could know that the code was written by more than one person.
The test suit took about an hour to finish.
Glorious days they were.1 -
I am deep onto a project that helps me learn a new lang, so of what ever resone I didnt implement testing of latest code jntil afterwards...
but when I wrote the test and it worked on first time... thene wrote test still worked.. wrote failing test and it failed... as it was suppose to...
*nagging feeling starts*
I am still convinced that some thing is wrong... but it is my personally hobby project so I have this terrified excited expectation of the future of my project xP
cannot decide if this is a rant or some thing else *cryies and laughs* -
Initialize a collection, store values in it and then filter values out of it and none of your code may be inefficient, such as having O(n)² performance. Your code must also pass the predefined Test Suite. You have 15 minutes.
This sounds simple but it's not.
This was for a Google-type company that has high standards.4 -
I've taken to only allowing PRs on my code if test coverage only deviates negatively within 1%
You can almost hear the tumbleweed.
But that hasn't been merged in yet -
In my company we are constricted to have 100% of f̶a̶k̶e̶ coverage with unit test.
Obviously the test suites are not performing and it takes more than 8 minutes to run 3335 tests.
I know that what I'm going to say is super mainstream but there is nothing comparable to the relief that comes from seeing all tests in green after you did a lot of small changes around the code on Friday.4 -
That kind of devs that creat unit test for a method never used in code instead of deleting it. #CoverageGoals
-
Dealing with government bureaucracy today. Prepare for pure anger.
First of all, what fucking dipshit site does testing and maintenance in production without letting users know? Bitch I'm getting an invalid date error when I use your own stupid date selector and I had to waste the office lady's time asking about it because you couldn't be arsed to either test your shit properly or actually take it down if it's broken. Who made that stupid ass decision and why the fuck did nobody question it. Fuck you.3 -
Jonathan Burnhams
Started my career under him, learnt a lot from him....writing neat and simple code, with always 100% test coverage.
Very strict and straight forward. -
Already starting to regret trying to learn c++ AND test driven development at the same time. Do you think i can even get the boost-test headers located anywhere from a binary package installation.
3 days on no learning code cause i cant even get the testing suite up and verified.1 -
Hey guys. Days ago I was working in some "Unity2d animation test". You can download the demo apk and see the code here: https://github.com/Marks7e/Test
Give me your feedback please ♥️2 -
So I'm working on this codebase that has about 50k lines of code and I built a feature in it today. Spent 3hours on the feature + writing tests. Then I raised a pull request and that bastard codeclimate calculated the test coverage had dropped by 0.3%.
For 6hours now I'm still looking for a way to increase the test coverage by 0.2%. FML4 -
Damnnn my Team lead is hinting that i write a test for the feature I paired with a team member.
But the large django code base is ridden with abstract classes and classes and inheritance etc...its going to be a long night -
It seems I am developing a habit to always forget to test "fetch" code in a repository, found two unit tests having all insert/update/delete but not a single fetch function T_T
-
Can someone explain tests to me? Maybe I'm a little behind but like, don't you test your code when you run it? Why do you have to write tests instead of just running the code you wrote and testing that?5
-
Writing a test helper that handles all the fuckery with DB connections and transactions when the legacy under test uses multiple DB connections is so 👌👌👌👌👌👌👌👌👌👌👌👌👌👌
I can write tests for code that was untestable before 💦💦💦
*nerd-gasms*2 -
When you forget to push the code on Git, you reload the website and nothing has changed. Go back to code to tweak some more and then push to Git. Now you have to go back to code to remove the extra tweak you've done and test again... 😅
-
Immediately after the last major release, I enabled CheckStyle to fail on unused methods and variables, and then I proceeded to delete all dead code. The test suite passed and I got approval to merge. Two months later, the next major release went out the door…guess how that went :)
Using TDD or at the very least writing unit tests ensures your code won’t break, or go missing!1 -
Why the hell you write test¿ if you can write 8h a day perfect working code, everyday, without a mistake?
You just waste time doing that...
</irony> -
Finally on github.
https://github.com/FidelityInternat...
I use this to test the css changes to my ui.
It's still a work in progress, not even documented properly, but I'm just happy that company allowed this code to go open sourced. -
What if those users that go and like all your rants one by one.. are actually devRant test users and its just @dfox testing code?
😯1 -
I'm gonna enter in school tomorrow, in the presentation, they told us that during the "piscine" (a test phase to put everyone on the same level), we have to make code with functions with less than 5 lines of code inside it to validate the exercise. Do you think it's the good way to make a program?
-
I'm starting to gain a dislike for OOP.
I think classes make it easy for me to think of the entities of a problem and translate them into code.
But when you to attempt to test classes, that's when shit hits the fan.
In my opinion, it is pointless to test classes. If you ever seen test code for a class, you'll notice that it's usually horrible and long.
The reason for this is that usually some methods depend on other methods to be called first.
This results in the usual monolithic test that calls every goddamn method on the class.
You might say "ok, break the test into smaller parts". Ok. But the result of that attempt is even worse, because you end up with several big tests cases and a lot of duplicate code, because of the dependency of some methods on others.
The real solution to this is to make the classes be just glue: they should delegate arguments onto functions that reside on its own file, and, maybe afterwards emit events if you are using events.
But they shouldn't have too much test code classes though. The test code for classes should be running a simple example flow, but never doing any assertions other than expecting no exceptions.
For the most part, you'd be relying on the unit testing that is done for each delegated function.
If you take any single function you'll see that it's extremely easy to write tests for it. In fact, you can have the test right next to the fuction, like <module>.xyz <module>.test.xyz
So I don't think classes shouldn't be used at all, they should just be glue.
As you do normal usage of this software this way, when a bug is discovered you'll notice that the fix and testing code for this bug is very usually applied to the delegated functions instead of being a problem of classes.
I think classes by themselves sound sane in paper, but in practice they turn into a huge fucking messes that become impossible to understand or test.
How can something like traditional classes not get chaotic when a single class can have x attributes and y methods. The complexity grows exponentially. And sometimes more attributes and methods are added.
Someone might say "well, it's just the nature of problems. Problems can have a lot of variables".
Yeah, but cramming all of that complexity into a single 200 lines class is insanity.12 -
So, I'm an engineer who believes that there isn't one solution that fits all (feel free to change my mind). I believe 100%, that a great engineer is someone who also encompasses the ability to make decisions appropriately on tools, paradigms, etc to solve any problem.
But, this rant is going out to the TDD fanatics.
I assume every piece or lines of code you write is/are towards solving a problem and it includes the code you write to test the "main" code you are about to write 😑
Question: Do you write a test to test the test you write to test the code you about to write? 😏7 -
Test your code. Take extra time to do self-review. It'll improve your code quality and position within your peers.
When you enter that "minor change-trial-error" phase. Go to sleep or take a long break. You're loosing time and adding more work to be reviewed and corrected later -
Congratulated a Dev at my company after he had finished all the functional testing...
Until he mentioned that he just needs to tweak the test to work with the new code now.. -
Vinegar didn't work, time to test honey.
Let's see if autocomplete is nice enough to persuade some of these mongrels to evolve from dogs to chimps and actually document the code they write.1 -
<!-- no-rant -->
I want to start testing my code... are there any good resources about testing code? (what piece of the code should I test?) preferably .NET C#4 -
I have been writing unit test cases after writing the code. Not the other way around. I do not think this is TDD . Is it ATDD?
Should I keep going on with this?
Thoughts?8 -
I had a mandate to help bring a couple of fellow QA testers up to speed on basic automated test code, fill in any knowledge gaps and answer questions.
Met with one co-worker and figured I'd start with his questions and work from there. He opened his test code and said he focused on learning 'if statements' last week but his test isn't running and just throwing errors.
Upon inspection, I realized it was a deeply nested (sometimes 10 or more conditions) single method soup that had never been run through even a syntax check. I blinked... *coughed* and spent the next few hours trying to "port the desired functionality" to a new file while he watched. -
How would you java spring guys write a JUnit test for a login controller? My controller works as followin: It checks the username and password values from the model and then either redirects to the home page or redirects to the login page with an error code. How am I supposed to test that behavior, when MvcMock can't capture the redirects?1
-
I just want to test my PHP code using phpunit on GitLab, what am I doing wrong?
image: php:latest
before_script:
# Install & enable Xdebug for code coverage reports
- pecl install xdebug
- docker-php-ext-enable xdebug
# Run our tests
# If Xdebug was installed you can generate a coverage report and see code coverage metrics.
test:
script:
- phpunit Test.php4 -
Any .Net gurus about? Got a question about testing how many open connections I have.
https://stackoverflow.com/questions...2 -
Forced to write UT on excel shiit for confirming test cases are covering units properly, but the reviewer even don't want to read test code!! it makes incredibly unmaintainable documents
-
I want to learn, How to add test cases in android And also about layer code pattern. like Controller, View, model, persistence, network etc...
So Please suggest a few tutorial or blogs that help me.
And please give me some links that have a test for network functions and intent related test.
Something like the test for other methods that work of different thread. (Asynk task, Volley or etc..).1 -
When your only QA guy describes your QA process as "we just put a bunch of stuff in the code base and test"
-
The most fuckin irritating thing when code is terminated due to timeout of just 4 test cases out of 14 in this case 😥af...but never give up 😎2
-
When you're working with a QA/test engineer that insists on manually testing code that have automated tests. Can any test engineera chime in here?
-
So fucking today i wanted to test netbeans ide..installed, no problem..then i wanted to compile code an it said fucking error ,netbean connector and google chrome? Wtf do i need this shit ?!4
-
Hey rants! So I am going to test Balmer curve once again! Preparing regression model for altered SIR model with time dependent parameters (for Covid). Wish me successful code!
-
When you have a BA who types things to prove that they do work, then you get to be the BA too. Good thing that architecture, test design, code quality, and sanity aren't really a priority.
-
tfw you find a bug in a toolchain using unmodded 10 year old code that's so bad it needs an entire branch to test on
https://github.com/ps3dev/PSL1GHT/...
This is probably the biggest contribution i'll make to anything -
Audience question to Uncle Bob: Which parts of the code do you unit test? What about code coverage?
Uncle Bob: Well (chuckling).. You test the parts of the code that you want to work. -
Leverage online code platforms for exercises/assesments. Something like qualified.io for educators.
Teach algorithms with code challenges with sample test cases. Builds confidence, makes learning fun, and gives immediate feedback.