All Downloads are FREE. Search and download functionalities are using the official Maven repository.

arjuna.tpi.guiauto.GuiDriverExtendedConfig Maven / Gradle / Ivy

Go to download

Arjuna-Java is the client implementation in Java for development of test automation using Arjuna. It uses TestNG as the test engine. With minor tweaks, it can be used with any other test engine or custom test automation implementations. Arjuna is a Python based test automation framework developed by Rahul Verma (www.rahulverma.net)

The newest version!
package arjuna.tpi.guiauto;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class GuiDriverExtendedConfig{
	private Map capabilities = new HashMap(); 
	private List browserArgs = new ArrayList();
	private Map browserPreferences = new HashMap(); 
	private List browserExtensions = new ArrayList(); 
	
	public GuiDriverExtendedConfig capability(String name, Object value) {
		this.capabilities.put(name,  value);
		return this;
	}
	
	public GuiDriverExtendedConfig browserArg(String arg) {
		this.browserArgs.add(arg);
		return this;
	}
	
	public GuiDriverExtendedConfig browserPreference(String name, Object value) {
		this.browserPreferences.put(name,  value);
		return this;
	}	
	
	public GuiDriverExtendedConfig browserExtension(String path) {
		this.browserExtensions.add(path);
		return this;
	}
	
	public Map asMap(){
		Map map = new HashMap();
		map.put("capabilities", capabilities);
		map.put("browserArgs", browserArgs);
		map.put("browserPreferences", browserPreferences);
		map.put("browserExtensions", browserExtensions);
		return map;
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy