1. Introduce the JAVA+SELENIUM+POM Automatic test framework, the first to realize the separation of code and account URL and other information. The 2nd supports cross-browser implementation by reading the configuration file.1) Add information such as account URL to the properties file and read2) write the browser class by fetching the configuration file to achieve browser switching3) Test Browser classProject structure:1. Create a new folder place the
I use the Java Juint Framework to organize the automated tests, so I need a brief introduction to the Juint frameworkFirst of all, it is recommended that Baidu Juint frame, first have a rough understandingThe so-called Interface Automation test will send a variety of requests to each interface in multiple interfaces, and its main thinking is the following way Can think of, we want to simulate the test, is
native browser to clear and choose the correct, the driver of the road to the System Properties (Webdriver.ie.driver);IE browser start, need to pay special attention, be sure to close the browser protection mode;qq picture 20161115211739.png1146x765 148 KB Of course, we do not need to manually protect the mode, you can start the browser process, the browser to set the startup parameters, remove the protection mode;qq picture 20161115213803.png1593x941 146 KB The final explanation: every browse
driver.findelement (By.xpath ("//*[@type = ' text ']");}); Textinputbox.sendkeys ("Custom explicit wait 1"); /* * 5. Custom display wait, get page element//a[text () = ' about Sogou '] text value */string Text = (new webdriverwait (Driver, Ten)). Until (new Expectedcondition@Override publicString apply(Webdriver driver) {return Driver.findelement (By.xpath ("//a[text () = ' about Sogou ')"). GetText ();}); System.out.println (text); //Print text value}}
To customize an exp
This is a method that can be called directly in mainprivate static void ie () {Webdriver Driver;IE started successfully, files is to start IE driverSystem.setproperty ("Webdriver.ie.driver", "Files/iedriverserver.exe");Code off IE some configurationDesiredcapabilities DC = Desiredcapabilities.internetexplorer ();Dc.setcapability (Internetexplorerdriver.introduce_flakiness_by_ignoring_security_domains, true);Dc.setcapability ("Ignoreprotectedmodesettings", true);Load shutdown configuration into I
choose build periodically, which is explained in the schedule parameters:
The first parameter represents the minute minute, the value 0~59;
The second parameter represents the hour hour, the value 0~23;
The third parameter represents the day, value 1~31;
The fourth parameter represents the month, the value 1~12;
The last parameter represents the week week, and the value 0~7,0 and 7 are all represented in Sunday.
The 0 * * * * indicates that the build is performed i
1. Create a new MAVEN project2.2. Add dependency, Load Jar package (Pom.xml) Add dependency:3. Importing the JAR PackageMAVEN + Java+testng Implements interface Automation (1)
How the CVS client is used in eclipseBasic situation: In Eclipse has been self-contained CVS client plug-in, directly can link to the CVS server, but need to pay attention to the link information, must be with the previous on the CVS server, set the information consistent;How do I link a CVS server?In Eclipse, select an existing project, such as: Testng_workspace (one of My Learning project names), as shown in:When the tab is selected, the system pops up with the corresponding dialog box, as sho
What is ANT?Apache Ant is a Java-based build tool. According to the original founder James Duncan Davidson, the name of the tool is the initials of the another neat tool (another neat tool).
Ant's Role:build tools are used in software development to convert source code and other input files into executable files (and may also be converted to an installable product image form). As the process of application generation becomes more complex, it becomes
by more than 68% Java developers, is a project management build tool that provides a unified build system, quality project information, and best-practice development guidance. The main features of MAVEN include:Simple project settings that follow best practicesSuperior dependency management, including Automatic Updates and dependency closuresAbility to handle multiple projects at the same time with easeA large and growing library and metadata reposit
Huawei Computer Testing Questions (expression calculation-java), Huawei-java
PS: Self-written, self-tested OK for your reference.
/** Enter an expression (3*8 + 7-2) with no parentheses to output the result.*/
/* This program does not consider fault tolerance Processing for the moment */
1 import java. util. iterator;
/etc/profile. Again, we want sudo nautilus to find the file, and then add it at the endNote that this is for experienced students to say. In Jdk10, there is no JRE directory, so in the configuration we do not need to configure the JRE information.Save, close.Ps: can also be used in terminal via command: sudo vim/etc/profile Open Text editor, press Typing commands in the terminal,Source ProfileAlternatively, we can restart Ubuntu and let the configuration take effect.Now, let's hit the command
Pragmatic unit testing in java with JUnit-- Unit test background
My internship in the company has been very fulfilling for the past two weeks, but I am also very tired. I am tired of working in a different way than before. Although the tone is the same, there are many differences in details, the current project is very large and important. The technical manager intends to adopt a more standardized and stric
I heard that javastore has started beta testing. Although Sun is always slow to do anything, we should support it unconditionally as a Java programmer, so I just went to join in.
First Login http://www.java.com/en/store/index.jspThis is the homepage of the Java Network store.
We learned from the homepage that the application address for beta
Java testing, java interview
1. Can a ". java" source file contain multiple classes (not internal classes )? What are the restrictions? ,
There can be multiple classes, but only one public class is allowed, and the public class name is the same as the file name
2. Does Java
[JAVA concurrent programming practice] 10. concurrent program testing and java practice1. Generate a random number
Package cn. study. concurrency. ch12; public class Util {public static int xorShift (int y) {// shift left and unsigned right, and last XOR operation (XOR, if the two bits are different, the value is 1; otherwise, the value is 0) y ^ = (y
2. cache
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.