Some parts of the world reserve a discrete squawk code for use by military interceptor operations (in the NBCAP, code 7777 is used for this). Does this squawk code, or some equivalent value, suppress TCAS RAs from other aircraft, or is turning off their Mode A/C/S transponder replies the only way an interceptor can avoid triggering a TCAS RA from a TCAS-equipped aircraft? Is some sort of Letter of Agreement used to keep track of interceptors in areas where transponding is mandatory but interceptors cannot squawk during intercepts, or during intercepts outside of primary radar coverage where the interceptor is unable to squawk?
To avoid an RA, the interceptor would almost certainly turn off at least his Mode C, and to avoid a TA and the concern in the intercepted aircraft of "what is this no-altitude traffic doing closing rapidly on me???" he will probably turn off his squawk altogether before he gets to the last few miles of the intercept. (There were cases years ago when TCAS was pretty new of intercepted aircraft getting a series of RA's as interceptors -- squawking everything -- closed on them, maneuvering to continue the intercept even as the target climbed and dived all over the sky in response to the RA's. That scenario is undesirable for all sorts of reasons!)
A wingman may well hold a squawk and park himself some miles in trail of the target, monitoring both the interceptor and the target with his own air-to-air radar. ATC can see the wingman and the target, and knows that there is an interceptor somewhere between them -- which is probably enough for their purposes.
Each specific case probably has letters of agreement between the ATC facility and the specific interceptors, so they'll all know in advance who's where, doing what, squawking or not squawking what, and who's talking on which frequencies. Those sorts of specifics probably aren't available in the public domain.
As it turns out, it's not keyed off the squawk code after all
Since different regions of the world use different beacon (squawk/SSR) code allocation schemes, having TCAS RA suppression keyed off a special "squawk" wouldn't work so well. However, there is generally functionality to allow military interceptors to prevent errant RAs from interceptees, or at least that's what ICAO foresees as present in Appendix 7 of ICAO Doc 9863, aka the "master document" national aviation authorities work off of when setting their requirements for ACAS. Furthermore, there is a difference between the "legacy" (Mode 3/A/C) and the "new style" (Mode S, 1090ES) transponders in this regard, although it likely is implemented in the same way by the intercepting pilot.
For grizzled greybeard fighter jets...
If the interceptor does not have Mode S/1090ES support itself, there are two ways the interceptor can prevent a RA aside from strangling its squawk altogether, which is highly undesirable during peacetime or wherever primary radar coverage is unavailable. First, the interceptor's transponder can ignore Mode C interrogations entirely, which is useful for covert intercepts, but means that the interceptee's ACAS won't generate a TA or display icon for the interceptor. For demonstrative intercepts (such as in a lostcomm situation), where a TA is desired but a RA needs to be suppressed, the interceptor needs to generate a Mode C reply containing only framing pulses (i.e. no altitude data) in that case.
As to how that plays out in practice, older F-16s (and older F-15s as well, as they use a similar transponder interface) had the ability to cut out Mode C, but it's not known if that suppresses framing pulses or just the altitude data, while their F/A-18 counterparts transmit framing pulses only (aka sending an altitude reading of 0) when Mode C is disabled.
Things change with this newfangled Mode S tech, though
Modern jets, or older fighters with modern transponders capable of Mode S operation, handle things differently so that they can still provide altitude readouts to ground interrogators (ATC) while suppressing responses to aerial (ACAS) interrogations. In particular, for covert intercepts, an interceptor's Mode S transponder needs to ignore DF0/DF16 interrogations, while a demonstrative intercept simply suppresses the altitude returned to such an interrogation instead. The ICAO documentation says this behavior is part of an "Intercept Mode", but I am not sure how it's activated on today's military aircraft; my guess is it's a menu item somewhere, but there could be a dedicated switch or key, depending on the aircraft in question.