A standard attache case is about 18" across.
An M4 upper will not fit into it.
UNLESS you have an MGI QCB upper receiver which will let you quickly remove/replace the barrel, and the whole thing will then fit right into an attache case, as long as you use the 14.5" or 11.5" barrels.