2017-2018-2 20165313 Experiment 3 "Agile Development and XP Practice"

lab report cover

Experiment content and steps

experiment one

1. Test requirements:
Refer to http://www.cnblogs.com/rocedu/p/6371315.html#SECCODESTANDARD to install the alibaba plug-in to solve the specification problems in the code.

Use the tool (Code->Reformate Code) in IDEA to reformat the following code, and then study the Code menu to find a function that makes you feel the best. Submit a screenshot and add your student ID watermark.

public class CodeStandard {
public static void main(String [] args){
StringBuffer buffer = new StringBuffer();
buffer.append('S');
buffer.append("tringBuffer");
System.out.println(buffer.charAt(1));
System.out.println(buffer.capacity());
System.out.println(buffer.indexOf("tring"));
System.out.println("buffer = " + buffer.toString());
if(buffer.capacity()<20)
buffer.append("1234567");
for(int i=0; i<buffer.length();i++)
System.out.println(buffer.charAt(i));
}
}
2.实验截图:

Experiment 2

1. Experiment requirements:
Add your learning partner to your own project on the code cloud. After confirming that your partner's project is added to yourself, download the Complex code of partner experiment 2, and add no less than three JUnit unit test cases. After the test is successful git add .; git commit -m "Add content to your student number"; git push;

Submit a screenshot of the partner project git log, including the above git commit information, and add your own student number watermark information.
2. Experimental screenshot:

Experiment 3

1. Experiment requirements:
complete the refactoring exercises, download the code of your partner, perform at least three refactorings, submit a screenshot of the refactored code, and add your own student ID watermark. Submit your partner's code cloud project link.
2. Experimental screenshot:

https://gitee.com/FenixRen

Experiment 4

1. Experiment requirements:
refer to http://www.cnblogs.com/rocedu/p/6683948.html to complete the learning of Java cryptography related content in pairs, combined with refactoring, git, and code standards .
Submit the learning outcome code cloud link and representative results screenshots, with a student ID watermark.

2. Experimental screenshot:

3. Test results

test questions

When writing the final draft of the Caesar cipher, when es-=c is used in the decryption part , it fails to compile.

solution

Replace the key Key with -key.

PSP time

step time consuming percentage
demand analysis 30min 18.75%
design 40min 25%
Code 30min 18.75%
test 20min 12.5%
analysis Summary 40min 25%

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325069267&siteId=291194637