Original Reddit post

Straight to the point: I’ve been using claude code to run tests inside of Chrome for my extension using the Claude-in-Chrome skill. Needless to say, it consumed a lot of tokens running the tests and a lot of time. I made it access the console and execute the extension functions that are used to interact with the website. That helped a lot with the testing. In my case CC told me that every screen shot he took to find the results visually was costing me 7k tokens each… I made some small changes that helped saving the token usage, but the testings were still consuming a lot of tokens even on every task/new session technique. Fast-forward to today, I discovered that they just recently released the CLI which CC can interact directly with. What this means? CC interacts with it and doesnt consume tokens browsing the website, executing commands “manually” and taking screen shots. The web testing can be done headless. In my case I still need to have a tab open so it can interact with the extension. I noticed a MAJOR improvement in token consumption, bug findings and the speed of the implementations and patches. You can find the CLI and the Claude skills in their github and the official website. You can also give those links to claude and tell him to install it automatically. Works wonders. PLAYWRIGHT My mistake ** TDLR: If you’re developing and testing for Chrome/Firefox, get Playwright CLI for automatic testing. Saves tons of tokens** submitted by /u/UnusualRedditor

Originally posted by u/UnusualRedditor on r/ClaudeCode