$$NX ≡ (S-I) + (T-G)$$ Read this as “the trade balance (net exports) is identical to the sum of net savings (savings minus investment) and the government’s budget surplus or deficit (taxes minus spending).” This is not a theory of what causes what; it’s an identity, different ways of expressing the same “what”.
Let's say the U.S. had a $NX$ or trade deficit of $500$ billion dollars and overnight the U.S. forced countries around the world to buy $1$ trillion dollars of U.S. military equipment giving the U.S. a trade surplus of $500$ billion. Does this mean that the equation: $NX ≡ (S-I) + (T-G)$ doesn't take into account non-macroeconomics factors and therefore is wrong?