, Claude Code works fairly properly. You may enter a sequence of directions and have it produce code or different output for you. Nonetheless, there are some things you are able to do to vastly improve the efficiency of Claude Code, particularly relating to programming.
On this article, I’ll speak concerning the primary approach that I’m utilizing each day to make my Claude Code a number of instances more practical: automated / more practical testing.
On the floor, this would possibly sound like a boring subject, however while you be taught extra about it, testing, particularly when automated or made more practical, is an effective way to save lots of a whole lot of time. If you may make the agent check its personal implementations, that can make it far more practical at producing the answer that you just wished to make.

Why automate testing
The primary purpose why it’s best to automate testing is that it merely makes you far more practical. In case you can have an agent check its personal implementations routinely, it’s going to turn out to be much better at truly managing to implement the answer you describe in your immediate. In the end, this results in you saving a whole lot of time since you don’t should iterate with the agent a number of instances to get the precise resolution you need.
Moreover, one other vital level is that now that coding brokers have turn out to be so efficient at producing code, the true bottleneck with programming has turn out to be testing. It’s worthwhile to check that the implementation truly works in accordance with what you take into consideration. I discover that I spend most of my time programming, testing totally different options, and ensuring every part is working as anticipated. If you may make testing both more practical or fully automated, that can thus resolve the most important bottleneck I’ve in programming, which can naturally make me far more practical.
I consider this is applicable to lots of people who actively use coding brokers to program, and I’m simply sharing how I each automate and make my testing more practical.
The best way to automate testing
I’ll speak about a couple of elements with regard to testing. First, I’ll speak about automating testing, which is while you give your agent entry to run checks itself. This may occur in many various methods. You may, for instance, give it testing scripts to run, unit checks to run, or full-on integration checks. Persevering with, I’ll talk about the best way to make testing with people more practical. Generally it’s not attainable for the coding agent to totally do the check itself. Perhaps it requires particular context or permissions. Perhaps it’s an advanced motion inside a UI that you just don’t need the coding agent to do, or that the coding agent can’t do, and so on.
Agentic computerized testing
Listed here are the three primary steps for computerized testing:
- Ensure the agent has all of the permissions it wants
- Immediate the agent to arrange checks and check its implementations
- Ensure the checks all the time run earlier than commits or merges, relying on while you need them to run.
- Guarantee all new code will get up to date checks and generally take a guide take a look at the checks to ensure they work and do what you assume they do.
I’ll begin by discussing how one can give the agent entry to operating checks. A very powerful level you’ll be able to word right here is that it’s best to make it attainable for the agent to run checks. That is executed by giving it sufficient entry, for instance, possibly it wants AWS entry to entry knowledge, or possibly it wants entry to the browser to navigate by way of the appliance. Thus, step one right here is to make it possible for the agent has all of the permissions it wants.
In my expertise, you’ll be able to run Claude Code with Dangerously Skip Permissions or Auto Mode, which was not too long ago launched, and it really works very properly. Sadly, when utilizing different coding brokers resembling Gemini or Chachipetee, I’ve not executed this but as a result of I even have some experiences the place the coding brokers have executed unintended actions that have been non-reversible. Nonetheless, this has by no means occurred after I used Claude’s fashions.
The second a part of automated testing is solely to immediate the agent to arrange checks. For instance, I ask my mannequin to arrange integration checks. Integration checks are basically only a sequence of API calls that make sure that the movement by way of the appliance is as anticipated. And with coding brokers, this works rather well. For instance, have an LLM name that leads right into a parsing pipeline and so forth. You can also make the method deterministic and make sure the outcomes are right each time. Merely informing the agent to arrange integration checks will work rather well; the mannequin will arrange the checks and truly instantly work higher.
You too can simply ask the mannequin to create testing scripts that check an implementation and inform it that it ought to run that testing script to ensure every part works as supposed, and never cease till the testing script works efficiently. The final half is essential as a result of generally the fashions are literally a bit lazy, and you’ll want to explicitly inform them that they’re not allowed to cease earlier than the implementation is profitable. This, in fact, assumes that the implementation is feasible given the permissions and actions you’ve given to the coding agent.
Persevering with, it’s additionally vital that you just make it possible for these checks run earlier than the code is pushed to manufacturing. You may run the check as pre-commit hooks, although this could gradual you down generally as a result of the checks should run earlier than each commit, and if the check takes a while, then it’s going to gradual you down. You too can make them run each time you might have a push, a brand new push to a pull request. I.e., if a pull request is up to date, then run integration checks. These checks will also be a part of GitHub actions, for instance, so that they routinely run, and also you don’t should run them in your laptop. Nonetheless, in my expertise, it’s usually good to have these checks in your laptop, because it makes it sooner and you’ll extra simply set off them.
Lastly, on the automated testing part, I need to spotlight how you’ll want to just remember to consistently replace your checks given new code that’s produced. For instance, should you produce a brand new piece of code, make sure that so as to add new checks for it. And should you take away previous code, make sure that to take away the corresponding checks. It’s vital to take care of the checks in order that they’re efficient. Although this upkeep would possibly sound like additional work upfront, it’s going to truly prevent time in the long term since you’re not operating pointless checks, and also you’re making certain that every one your code is examined, which lowers the possibility of bugs.
Moreover, I like to recommend that you just generally manually examine the checks by actually trying on the enter and output and asking the agent to indicate you the outcomes. This guide inspection of checks can generally be very efficient in making certain the check works as anticipated and makes it straightforward to find bugs within the check.
Make guide testing more practical
The second level on testing I need to cowl is making guide testing more practical. Once I speak about guide testing, I imply testing that requires a human to carry out it, and that may’t be executed by an AI. Sadly, some testing must be executed by you, and you’ll’t merely outsource it for an AI to do. This might occur due to a number of causes:
- The duty is simply too difficult for the AI to carry out, and you’ll want to carry out it your self
- The duty contains one thing the AI doesn’t have entry to or permission to. For instance, it requires admin entry that you just don’t need to give to your AI, or it makes use of audio that the AI doesn’t at present have entry to.
- The duty is simply too difficult for the AI to carry out, and also you don’t belief it to carry out it accurately.
In these circumstances, the most effective factor you are able to do is to make the testing more practical for your self. In fact, your first intuition when producing checks ought to all the time be to attempt to automate them totally so that you just don’t should ever contact them your self, and the AI all the time runs them routinely. Nonetheless, realistically, you’ll want to check it lots your self as properly.
My primary trick to make testing more practical is to make use of visible testing. For instance, if I’ve the AI resolve a whole lot of duties for me, I first make it create an HTML report consisting of every process and a checkbox beside these duties so I can verify off any duties which are set to executed. I additionally inform the AI to supply me with hyperlinks to the pages that include the content material I would like to check and the outline of precisely how I can check that it really works. This simplifies the method lots as a result of I don’t have to recollect every part I would like to check and the best way to check it. Nevertheless it’s consciously introduced to me in a report. You may see an instance of this under:

One other level in how I make testing simpler is that I attempt to outsource as many duties as attainable to the coding agent. For instance, if I would like specific knowledge to check one thing manually, I don’t spend a whole lot of time manually on the lookout for the info. I ask the coding agent to entry the required assets and discover me the info routinely.
Conclusion
On this article, I’ve mentioned how one can automate testing with Claude Code to turn out to be far more practical with Claude Code or some other coding agent that you just’re utilizing. I primarily mentioned how one can both automate testing, which is probably the most preferable strategy, or you may make guide testing more practical. When coding brokers have turn out to be pretty much as good as they’ve come, particularly after the discharge of the most recent Opus fashions, I consider testing has turn out to be the bottleneck. Whereas beforehand you spent probably the most time manually writing code, you don’t spend that a lot time manually writing code anymore, and also you spend way more time testing the precise implementations. Thus, it is sensible to attempt to optimize the testing course of to make it more practical. To maximise your effectivity as a programmer, I might undoubtedly give attention to the testing half and take into consideration how one can turn out to be more practical there. The strategies I introduced on this article are just a few examples of what I do personally to make testing more practical.
👉 My free eBook and Webinar:
🚀 10x Your Engineering with LLMs (Free 3-Day Electronic mail Course)
📚 Get my free Imaginative and prescient Language Fashions e book
💻 My webinar on Imaginative and prescient Language Fashions
👉 Discover me on socials:
💌 Substack
Additionally, try my article on The best way to Maximize Claude Cowork.
















