Funny you should ask. I just went through this exercise for some metal joints that I had to spec recently. Here's what I came away with, primarily based on ASME B31.3 Appendix X:
The test pressure shall be the lesser of these two equations:
1.5 * Ps * (Et / E) (para. X302.2.3a)
Ps - Limiting design pressure based on column instability (squirm)
Et - Modulus of elasticity at test temperature
E - Modulus of elasticity at design temperature
OR
1.5 * Pd * (Sc / Sh) (para. 345.4.2b)
Pd - design pressure of the piping system
Sc - Allowable stress at test temperature
Sh - Allowable stress at design temperature
With the limitations that:
1. The test pressure not be less than 1.5 * Pd
2. The ratio (Sc / Sh) is capped at 6.5 max
3. The calculated test pressure does not lead to a stress in excess of yield for the material.
Ps and Pd are effectively going to be the same number from the end user's stand point, as best I can see. However, for the joint manufacturer, I can see that Ps could end up being higher than the design pressure called for on a spec sheet because Ps is defined in terms of the squirm pressure. Paragraph X302.1.1 defines a 2.25 factor of safety for the squirm pressure. So, it would have to be a minimum of 2.25x the design pressure that you specify. However, if, when they've done all their EJMA calcs on the design, the squirm pressure is predicted to be higher than 2.25x your design pressure, then Ps for the test would be that calculated squirm pressure/2.25. But, you really can't know when you're specifying a joint what the squirm pressure will be, since it will depend on what the joint manufacturer comes up with in detail design. In reality, I'd expect they're going to work the design to come up with a squirm pressure that is 2.25x your specified design pressure. To do otherwise would end up getting you more joint (and a stiffer joint at that) then you need.
I must admit, when I first looked at this, I thought that the test pressure for the joint would simply be the 2nd equation given above since that is what we normally call for as a test pressure for the piping system. After all, the joint is ultimately going to be installed in the piping system and that piping system is going to have to be pressure tested.
Then, with some more reading, I came across section 345.3.3, which specifically addressing testing a piping system with expansion joints installed. It says that a system with a joint installed shall be tested at the LESSER of
1. 150% of the expansion joint design pressure
2. The requirements of section 345 (equation 2 at the top for a hydrotest, and 1.1 * Pd for a pneumatic test)
From this, in the case of a high temperature joint, equation 1 will give the lower pressure for a hydrotested piping system and equation 2 will give the lower pressure for a pneumatically tested system. Since the piping system test pressure is limited to a max of 1.5 * Pd and the expansion joint shop test pressure shall be no less than 1.5 * Pd, you should not have an issue with a failure of the expansion joint during the system pressure test.
I must confess, I find it somewhat confusing that all the piping systems in B31.3 service have to satisfy the
1.5 * Pd * (Sc / Sh) requirement for testing, unless they have an expansion joint in them, in which case the temperature correction factor is essentially dropped. However, that looks to be exactly what the code calls for and seems to be a compromise recognition that metal expansion joints are a special case.
A few other things that I've picked up from this are:
1. If you have a system with expansion joints that are externally restrained by main anchors, you better make sure your anchors are good for the pressure thrust generated by 1.5 * Pd
2. You are going to want to make sure to coordinate closely with your project management on the testing of piping with expansion joints to make sure that the hydrotest pressure is limited to 1.5 * Pd.
Now, here's the disclaimer: I'm not a code committee member and these notes are just what I've been able to determine from my own review with the help of a few others. You'll want to check things out on your own and see what others have to say here about the issue. My research focused on a specific application, so I may not have covered all the generalities. That said, I hope it is helpful. Most times I'm asking questions on this forum and it is rare when I have the opportunity to try and offer an answer.