Code review tools you should get to know
Maybe you’re a project manager. Maybe you’re supposed to be shipping this week. Maybe it’s Monday morning and 95% of your team is still hung over. Oh and guess what? Their code is full of bugs. What to do?
Maybe you’re a developer. Maybe it’s Monday morning. Maybe you’re still a little ‘woozy’ from the weekend and your project manager is on your ass cause he “has to ship” this week, and your code is full of bugs. What to do, indeed?
Well, you could call neck-beard Steve from then next cubicle to come check your stuff out, but maybe you don’t feel like getting your keyboard full of cheeto dust. Looks like you need a code review tool. And you’re in luck because I happen to have a list ready right here in this very article. But first a little background info.
We generally speak of two types of code review tools: automated and manual. The former “checks source code against a predefined set of rules and produces reports” while the latter are used to “collaboratively inspect and discuss changes, storing the history of the process for future reference.” (wiki) We’ll be focusing on manual code review tools here, so what do you say we dive in and check out your options with today’s top code review tools.
To start, let’s take a look at Crucible by Atlassian which is one of the more popular options in today’s market. It is a web-based application primarily targeting enterprise. It facilitates asynchronous review and commenting on code and enables teams to collaborate easily.
Crucible integrates with other Atlassian products like Jira bug and issue tracking and their Bitbucket Server. Also, check out the Atlassian Marketplace for a whole slew of add-ons for customizing Crucible. They even offer a REST API if you want to build your own add-ons.
There are charts and reports, inline comments, threaded conversations, and activity streams showing recent comments and review updates.
The price is right too: free for 30 days and only $10 for up to 5 users.
Next up is Review Board, “an open source, web-based code and document review tool built to help companies, open source projects, and other organizations keep their quality high and their bug count low.” Notice that was code and document review. This means you can use it to review just about anything. Simply drag-and-drop a file onto a review request, and anyone can then leave comments on it. For example, use it for log files, console output, or even review and comment on UI and graphics.
Review Board has an advanced diff viewer (file comparison) that allows for expanding the code up to the nearest function or class, nearest code change, or by 20 lines at a time. It also features easy commenting, a web-based interface, and command line tools to simplify the review request submission process. The dashboard gives you an up-to-the-minute overview of all review requests.
Review Board is used by several big name companies (Linkedin, Mozilla, Yelp) and is free.
Parasoft offers a range of testing tools that have received many accolades, among them their Peer review for any language and file type. And for when manual code review isn’t enough, it integrates with other Parasoft software for unit testing, end-to-end functional and load testing, and service virtualization.
One great feature with Parasoft is the automation of workflow management—of preparation, notification, and tracking. New code is automatically identified and matched with designated reviewers, then the progress of each review item is tracked until closure. Developers simply check in code as normal, then review packages are prepared automatically and distributed to the appropriate reviewer’s IDE according to preconfigured reviewer mappings. Not bad! Supports all common development environments.
Collaboration Drives Innovation. Thus spake Abraham Lincoln. Well no, not really (he said don’t believe everything you read on the internet). That’s actually the tagline for Smartbear’s Collaborator—code review and document review for every development workflow (that’s their other tagline).
So what we’ve got here is peer review for source code and other documents, reports and metrics, sweet bug tracking features, and lots of integration: Git, Visual Studio, Team Foundation Server… yeah, pretty much with everything. It’s closed source, but hey that’s cool. It’s free for up to 10 users; after that you’re gonna have to get your boss to pay. They’ve also got some big name clients like Adobe, Oracle, HP, Bank of America and more.
Here, check out their flow chart. C’mon, we all love a good flow chart.
From IDE heavyweight JetBrains comes Upsource, the polyglot code review tool. Why polyglot? Here’s the list of languages where syntax highlighting is supported. No bad, but where’s the support for COBOL?
The first cool thing that stands out here is the ease of collaboration. Simply send a URL to share code, revisions, diffs, code reviews, search filters, files, and even code selections. Also, developers can take part in code reviews directly from their IDE via a plugin. It integrates with GitHub, Jira, and others, and has some nice analytics features. Definitely worth considering if you’re already using a JetBrains IDE.
Up next is Reviewable, which gets bonus points not only for being open source but also for having a rabbit with a monocle. In their words, it has “more features than you can shake a stick at”—a bold claim knowing there’s no shortage of rather tenacious stick-shakers out there. A few of the features in question:
- See only what’s changed since the last time you looked (even if rebased)
- Instantly diff any two revisions of a file, in one or two columns
- Hide spurious whitespace-only, merge, or rebase deltas
- Tracks reviewed files, unreplied / unresolved comments
- Comments map across code changes, never disappear
- Live updates and many more
Free and paid plans available.
Last we have Gitcolony, code management that doesn't suck (their words, not mine). Gitcolony’s shtick is all about pull requests. You can “create a virtual pull request and check the code while it's being written.” Nifty.
The idea here is that if a developer reviews code in smaller segments they’ll be more likely to focus on it and find issues and bugs. "Ask programmers to review 10 lines of code, they'll find 10 issues. Ask them to do 500 lines and they'll say it looks good” quotes their site. They may have a point.
They also have a linked pull requests feature if your project sits on multiple repositories. It will automatically link requests from different repos but with the same origin branch which can be merged simultaneously after review. Some other highlights include integration with QA, metrics about team performance, and more.
Well, that about does it. Now maybe it’s time to get some coffee, a couple aspirin, give one of these a try, and tell that whiny project manager pipe down. It’ll be ready to ship by Friday. Afternoon.