Software-testing-methods

提供:Dev Guides
移動先:案内検索

ソフトウェアテスト-メソッド

ソフトウェアのテストに使用できるさまざまな方法があります。 この章では、使用可能な方法について簡単に説明します。

ブラックボックステスト

アプリケーションの内部動作に関する知識がなくてもテストする手法は、ブラックボックステストと呼ばれます。 テスターはシステムアーキテクチャを知らず、ソースコードにアクセスできません。 通常、ブラックボックステストの実行中、テスターは入力の処理方法や場所を知らずに入力を提供し、出力を調べることにより、システムのユーザーインターフェイスと対話します。

次の表に、ブラックボックステストの利点と欠点を示します。

Advantages Disadvantages
Well suited and efficient for large code segments. Limited coverage, since only a selected number of test scenarios is actually performed.
Code access is not required. Inefficient testing, due to the fact that the tester only has limited knowledge about an application.
Clearly separates user’s perspective from the developer’s perspective through visibly defined roles. Blind coverage, since the tester cannot target specific code segments or errorprone areas.
Large numbers of moderately skilled testers can test the application with no knowledge of implementation, programming language, or operating systems. The test cases are difficult to design.

ホワイトボックステスト

ホワイトボックステストは、内部ロジックとコードの構造の詳細な調査です。 ホワイトボックステストは、*ガラステスト*または*オープンボックステスト*とも呼ばれます。 アプリケーションで*ホワイトボックス*テストを実行するには、テスターはコードの内部動作を知る必要があります。

テスターはソースコードの内部を見て、コードのどのユニット/チャンクが不適切に動作しているかを調べる必要があります。

次の表に、ホワイトボックステストの利点と欠点を示します。

Advantages Disadvantages
As the tester has knowledge of the source code, it becomes very easy to find out which type of data can help in testing the application effectively. Due to the fact that a skilled tester is needed to perform white-box testing, the costs are increased.
It helps in optimizing the code. Sometimes it is impossible to look into every nook and corner to find out hidden errors that may create problems, as many paths will go untested.
Extra lines of code can be removed which can bring in hidden defects. It is difficult to maintain white-box testing, as it requires specialized tools like code analyzers and debugging tools.
Due to the tester’s knowledge about the code, maximum coverage is attained during test scenario writing.

グレーボックステスト

グレーボックステストは、アプリケーションの内部動作に関する知識が限られている状態でアプリケーションをテストする手法です。 ソフトウェアテストでは、フレーズを知っているほど、アプリケーションをテストする際の重みが大きくなります。

システムのドメインをマスターすることで、テスターは常に、ドメインの知識が限られている人よりも優位になります。 テスターがアプリケーションのユーザーインターフェイスのみをテストするブラックボックステストとは異なります。グレーボックステストでは、テスターは設計ドキュメントとデータベースにアクセスできます。 この知識があれば、テスターはより良いテストデータとテストシナリオを準備しながら、テスト計画を立てることができます。

Advantages Disadvantages
Offers combined benefits of black-box and white-box testing wherever possible. Since the access to source code is not available, the ability to go over the code and test coverage is limited.
Grey box testers don’t rely on the source code; instead they rely on interface definition and functional specifications. The tests can be redundant if the software designer has already run a test case.
Based on the limited information available, a grey-box tester can design excellent test scenarios especially around communication protocols and data type handling. Testing every possible input stream is unrealistic because it would take an unreasonable amount of time; therefore, many program paths will go untested.
The test is done from the point of view of the user and not the designer.

試験方法の比較

次の表に、ブラックボックステスト、グレーボックステスト、ホワイトボックステストを区別するポイントを示します。

Black-Box Testing Grey-Box Testing White-Box Testing
The internal workings of an application need not be known. The tester has limited knowledge of the internal workings of the application. Tester has full knowledge of the internal workings of the application.
Also known as closed-box testing, data-driven testing, or functional testing. Also known as translucent testing, as the tester has limited knowledge of the insides of the application. Also known as clear-box testing, structural testing, or code-based testing.
Performed by end-users and also by testers and developers. Performed by end-users and also by testers and developers. Normally done by testers and developers.
Testing is based on external expectations - Internal behavior of the application is unknown. Testing is done on the basis of high-level database diagrams and data flow diagrams. Internal workings are fully known and the tester can design test data accordingly.
It is exhaustive and the least time-consuming. Partly time-consuming and exhaustive. The most exhaustive and time-consuming type of testing.
Not suited for algorithm testing. Not suited for algorithm testing. Suited for algorithm testing.
This can only be done by trial-and-error method. Data domains and internal boundaries can be tested, if known. Data domains and internal boundaries can be better tested.