Tomcat provides support for multi-level contexts as of v5.5.27 and v6.0.18. A multi-level context is when an application appears to be deployed to a sub-directory, such as random/location. When using Tomcat, you can name your WAR file using a # to indicate a directory change, so for the previous example, the war file name would be random#location.war. In order to use Cargo to deploy a war that is named in this convention, TomcatWAR.getContext() needs to be modified to accomodate the new convention.
Attached is a patch that does a regular expression replace of '#' with '/' for the context name. It does include a unit test to test the situation and a sample war file using the new naming scheme.