By default, the FxCop naming and design rules only fire on publicly visible types and members. There are a couple reasons for this:

  • The .NET Framework Design Guidelines, which FxCop enforces, only contains guidelines for publicly visible API. What internal Microsoft teams (and you) do with their internal types and members is completely up to them.
  • Noise. If you tend to wrap a lot of native types and members, then this internal API could be potentially fire numerous violations.

However, if you would feel like you would like to be consistent with both your internal and customer facing API, then a little known feature is the ability to override this default in FxCop.

To do this, simply do the following:

  1. Using FxCop, open your FxCop project
  2. Choose Project -> Options
  3. Choose the Spelling & Analysis tab and check Run all overridable rules against all targets
  4. Click OK

Unfortunately, it is not possible to currently change this in Visual Studio Code Analysis.