失敗したテストの隔離

失敗したテストによってビルド全体が失敗しないようにしたい場合があります。

これが有効な場合のシナリオには以下が含まれます:

  • 失敗したテストがあるにも関わらず成果物を作成したい場合。これはプラン ビルドの失敗時には実施できません。
  • 関連するテスト以外を隔離したい場合(テスト駆動開発(TDD)では、テストは機能が実装されるまで失敗します)。
  • おそらく、インフラストラクチャの問題または依存関係によって、テストが予測できない結果をもたらす可能性がある場合。
  • ビルドからテストを削除したいが、別の Bamboo プランに影響を与える可能性があるため、テスト ソース コードを変更または削除したくない場合。

Bamboo では、テストを隔離することで、プラン ビルド結果から任意のテストの結果を一時的に切り離すことができます。テストはプランがビルドされるたびに実行されますが、テストの結果はプランのビルド結果に影響を与えません。

テストが成功している場合など、必要に応じて、いつでもテストの結果をビルド結果に復元することができます。

All the quarantined tests for a plan are displayed on the Quarantined tests tab of the plan summary. The status bar for each test shows the recent build history of the test.

Enable test quarantining

To enable test quarantining:

  1. In the upper-right corner of the screen, select
    Administration bamboo administration icon
    > Overview.
  2. Under Plans, select Quarantine settings.
  3. On the Quarantine settings page, select Enable quarantine.
  4. 保存 を選択します。

Quarantine a failing test

  • You need plan administrator or build permission to quarantine a test.
  • Test quarantining must be enabled

To quarantine a test:

  1. Select Builds > All build plans > #buildresult to go to the build result where the test is failing.
  2. Select Quarantine for the failing test (in the Summary section of the build).

Restore a quarantined test to a build

  • テストを復元するには、プラン管理者権限が必要です。
  • Test quarantining must be enabled.

To restore a quarantined test to a build:

  1. Go to your plan's summary.
  2. Select the Quarantined tests tab.
  3. Select Unleash for the test to be restored.


最終更新日: 2023 年 10 月 10 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.