ExpectedSms.java

1
package fr.sii.ogham.testing.assertion.sms;
2
3
/**
4
 * Class used in tests for ensuring that the SMS is respected. It provides the
5
 * following information:
6
 * <ul>
7
 * <li>The expected message</li>
8
 * <li>The expected sender phone number</li>
9
 * <li>The expected receiver phone number</li>
10
 * </ul>
11
 * 
12
 * @author Aurélien Baudet
13
 */
14
public class ExpectedSms {
15
	/**
16
	 * The expected message
17
	 */
18
	private final String message;
19
20
	/**
21
	 * The expected phone number for the sender
22
	 */
23
	private final ExpectedAddressedPhoneNumber senderNumber;
24
25
	/**
26
	 * The expected phone number of the receiver
27
	 */
28
	private final ExpectedAddressedPhoneNumber receiverNumber;
29
30
	/**
31
	 * Initialize the expected SMS with the message, the sender phone number and
32
	 * the receiver phone number.
33
	 * 
34
	 * @param message
35
	 *            the expected message
36
	 * @param senderNumber
37
	 *            the expected phone number for the sender
38
	 * @param receiverNumber
39
	 *            the expected phone number of the receiver
40
	 */
41
	public ExpectedSms(String message, ExpectedAddressedPhoneNumber senderNumber, ExpectedAddressedPhoneNumber receiverNumber) {
42
		super();
43
		this.message = message;
44
		this.senderNumber = senderNumber;
45
		this.receiverNumber = receiverNumber;
46
	}
47
48
	/**
49
	 * @return the message
50
	 */
51
	public String getMessage() {
52 3 1. getMessage : replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → NO_COVERAGE
2. getMessage : replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → KILLED
3. getMessage : replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → KILLED
		return message;
53
	}
54
55
	/**
56
	 * @return the sender number
57
	 */
58
	public ExpectedAddressedPhoneNumber getSenderNumber() {
59 3 1. getSenderNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → NO_COVERAGE
2. getSenderNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → KILLED
3. getSenderNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → KILLED
		return senderNumber;
60
	}
61
62
	/**
63
	 * @return the receiver number
64
	 */
65
	public ExpectedAddressedPhoneNumber getReceiverNumber() {
66 3 1. getReceiverNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → NO_COVERAGE
2. getReceiverNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → KILLED
3. getReceiverNumber : replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → KILLED
		return receiverNumber;
67
	}
68
}

Mutations

52

1.1
Location : getMessage
Killed by : oghamtesting.it.assertion.AssertSmsSpec
replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → KILLED

2.2
Location : getMessage
Killed by : oghamcloudhopper.it.KeepAliveSessionStrategyTest.keepAliveButEnquireLinkTimeout(oghamcloudhopper.it.KeepAliveSessionStrategyTest)
replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → KILLED

3.3
Location : getMessage
Killed by : none
replaced return value with "" for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getMessage → NO_COVERAGE

59

1.1
Location : getSenderNumber
Killed by : none
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → NO_COVERAGE

2.2
Location : getSenderNumber
Killed by : oghamtesting.it.assertion.AssertSmsSpec
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → KILLED

3.3
Location : getSenderNumber
Killed by : oghamcloudhopper.it.KeepAliveSessionStrategyTest.keepAliveButEnquireLinkTimeout(oghamcloudhopper.it.KeepAliveSessionStrategyTest)
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getSenderNumber → KILLED

66

1.1
Location : getReceiverNumber
Killed by : oghamcloudhopper.it.KeepAliveSessionStrategyTest.keepAliveButEnquireLinkTimeout(oghamcloudhopper.it.KeepAliveSessionStrategyTest)
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → KILLED

2.2
Location : getReceiverNumber
Killed by : oghamtesting.it.assertion.AssertSmsSpec
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → KILLED

3.3
Location : getReceiverNumber
Killed by : none
replaced return value with null for fr/sii/ogham/testing/assertion/sms/ExpectedSms::getReceiverNumber → NO_COVERAGE

Active mutators

Tests examined


Report generated by PIT OGHAM