SmsUtils.java

1
package fr.sii.ogham.testing.sms.simulator.decode;
2
3
import fr.sii.ogham.testing.sms.simulator.bean.SubmitSm;
4
5
/**
6
 * Some utility functions for SMS.
7
 * 
8
 * 
9
 * @author Aurélien Baudet
10
 *
11
 */
12
public final class SmsUtils {
13
14
	/**
15
	 * Get the text content of the SMS. The alphabet/encoding is determined
16
	 * directly from the SMS bytes.
17
	 * 
18
	 * @param actual
19
	 *            the SMS
20
	 * @return the SMS content
21
	 */
22
	public static String getSmsContent(SubmitSm actual) {
23 5 1. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → NO_COVERAGE
2. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → TIMED_OUT
3. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED
4. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED
5. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED
		return MessageDecoder.decode(actual);
24
	}
25
26
	/**
27
	 * Get the text content of the SMS using a particular alphabet/encoding.
28
	 * 
29
	 * @param actual
30
	 *            the SMS
31
	 * @param charset
32
	 *            the charset used to decode the SMS message
33
	 * @return the SMS content
34
	 */
35
	public static String getSmsContent(SubmitSm actual, Charset charset) {
36 2 1. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → NO_COVERAGE
2. getSmsContent : replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED
		return MessageDecoder.decode(actual, charset);
37
	}
38
39
	private SmsUtils() {
40
		super();
41
	}
42
}

Mutations

23

1.1
Location : getSmsContent
Killed by : oghamall.it.sms.SmsSMPPGsm7bitTest.longMessage(oghamall.it.sms.SmsSMPPGsm7bitTest)
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED

2.2
Location : getSmsContent
Killed by : oghamtesting.ut.sms.simulator.SmsUtilsSpec
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED

3.3
Location : getSmsContent
Killed by : none
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → TIMED_OUT

4.4
Location : getSmsContent
Killed by : none
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → NO_COVERAGE

5.5
Location : getSmsContent
Killed by : oghamcloudhopper.it.PartialConfigurationTest.nothingConfiguredAndLongMessageShouldSendOneLongMessageUsingDefaultEncoding(oghamcloudhopper.it.PartialConfigurationTest)
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED

36

1.1
Location : getSmsContent
Killed by : oghamtesting.it.assertion.FluentSmsAssertionsSpec
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → KILLED

2.2
Location : getSmsContent
Killed by : none
replaced return value with "" for fr/sii/ogham/testing/sms/simulator/decode/SmsUtils::getSmsContent → NO_COVERAGE

Active mutators

Tests examined


Report generated by PIT OGHAM