Advanced Search
Search Results
47 total results found
Function Domain - Different Programming Languages
Equivalence classes
[here description of a valid eq. classes] [example 1] Show the equivalence classes for the function (Java language) boolean isEven(Integer number) [example 2] Show the equivalence classes for the function (SQL language) CREATE FUNCTION isEven(integer x) ...
Incorrect equivalence class division
[write a content here] [Example 1] Perform equivalence partition analysis of the following function (Java language): public static double abs(double number); Explain what mistakes can be made if one does not know the binary notation of floating-point nu...
Valid and invalid equivalence classes
Add content and analyze the following example: CREATE FUNCTION isEven(integer x) RETURNS boolean;
Test case creation procedure
Section 8.1.4 from the Textbook (without the example).
AI Chat Boots and equivalence classes
[Example 1] Present the prompt for ChatGPT and MS Copilot to solve the following problem: What is the input domain and the output domain of the following function (PHP language): function f($x) { \$y = \$x; } // there is no return statement [Example 2] ...
Basic definitions
[The Textbook, page 89] test condition coverage item test case coverage, test coverage coverage analysis [example] Describe listing 2.2 from the Textbook using above definitions in the context of instruction coverage test and edge coverage test
Example test set construction
Description of the method
Instruction testing is the simplest of white-box testing techniques. However, it requires a precise definition of what constitutes an instruction. Instruction is an element of code written in a specific programming language that represents the smallest indivis...
Example - insert sort
Task 1 introduction from section 9.1.2 of the Textbook + source code void insertSort(int a[], int length) { int i, j, value; for (i = 1; i < length; ++i)s { value = a[i]; for (j = i - 1; j >= 0 && a[j] > value; --j) ...
Test conditions and coverage items
Task 2. Derivation of test conditions. The test conditions are executable instructions. Note that our code one line of the program corresponds to a single instruction. All test conditions are for ET1. TC1: instruction number 2; TC2: instruction numbe...
Test cases
Task 1 section [krok4] of the 9.1.2 Task 2 Source code of the test programm include <stdio.h> void insertSort(int a[], int length) { int i, j, value; for (i = 1; i < length; ++i) { value = a[i]; for (j = i - 1; j >= 0 && a[j] > value; --j) { ...
Statement coverage and unreachable code
In this section we will show unreachable errors using the C language. Unreachable statements are statements that will not be executed during the program execution.1. Return Statement Before Print Statement #include <stdio.h> int main() { printf("text_...
Statement testing with MS Copilot
Task 1 (student 1) Using MS Copilot identify statements for the insertSort function. Assign a tag to for each identified statement. Present the list of statements with tags. Write the prompt and the chatbot answer. Discuss the result. Does it properly reco...
Statement testing with Chat GPT
You can use any other Chat Bot. If you do so, change the page title. Task 1 (student 1) Using a Chat Bot identify statements for the insertSort function. Assign a tag to for each identified statement. Present the list of statements with tags. Write the p...
Description of the method
9.2.1. Description of the Method The branch coverage criterion (also called edge coverage) requires that tests cover all possible control flows between basic blocks. In the terminology of the Control Flow Graph (CFG), this simply means covering all the edges ...
Branch coverage and unreachable branches
Task 1 For each example from the section "Statement coverage and unreachable code" (Task 1) of this book, create a Control Flow Graph and identify branches that are unreachable. Return Statement Before Print Statement #include <stdio.h> int main() ...
Example - insert sort
Let's reconsider the BubbleSort function from the previous chapter and create test cases for it that satisfy the branch coverage criterion. Step 1. Define the subject and test elements. The test element is the BubbleSort function. ET1: BubbleSort. Ste...
Test cases
Task 1 section [krok4] of the 9.2.2 without table 9.4 Defining test cases. We must provide such input data that all branches are covered. Lets consider the input case T = [5, 3]. For this array, the program will follow the patch p = B1 - B2 - B4 - B5 - B6 ...
Branch testing with MS Copilot
Task 1 (student 1) Using MS Copilot identify branches for the insertSort function. Assign a tag to for each identified branch. Present the list of statements with tags. Write the prompt and the chatbot answer. Discuss the result - compare it with the prev...