2

先週、TFS 2008 を TFS 2010 にアップグレードし、VS 2008 プロジェクトを VS 2010 にアップグレードしました。コード分​​析を使用して、コーディングの品質を向上させています。

しかし、コード分析のチェックイン ポリシーに関していくつか問題があります。

プロジェクトでコード分析を実行すると、コード分析に関する警告が表示されます。ただし、修正せずにチェックインしようとすると、VS 2010 までにポリシーの失敗に関する警告が表示されることが予想されます。しかし、VS 2010 は警告を表示せず、TFS 2010 はチェックインを受け入れます。

では、どうすればこれを解決できますか。

プロジェクトにチェックインする前に、コード分析の警告についてチーム メンバーに警告してもらいたいと考えています。

4

1 に答える 1

1

There is an easy way to do this, but you may not like it.

  1. Create a Code Analysis list in your solution Code Analysis Rule Set Figure: You can add Code Analysis configuration to a solution

  2. Configure the rules Configure Code Analysis Rules Figure: Setting Rules to error will prevent a build from succeeding

Now that you have this configured you will be able to set some of the rules to error out and thus preventing check-in based on the Build not being successfully.

于 2011-01-12T16:41:13.120 に答える