Trigger selenium-java test scripts after TFS build - java

I have a maven project in Jenkins (which is a selenium- java project), web-Developers use TFS , I want to execute my selenium tests as soon as developers push their code change to TFS.

If you are using the TFS2015 or later, to execute Java Maven Project in TFS with vNext build system, you can refer to this link for detailed steps: Build your Java app with Maven.
If you want to build in Jenkins and just use TFS as the Version Control System, you can refer to this article to know How to integrate Selenium C# .NET test automation codes with Jenkins.
Below articles also for your reference:
Create and run a Maven build on Visual Studio Team Services
Getting Started with Selenium Testing in a Continuous Integration
Pipeline with Visual Studio

Related

Service to generate spring boot executable jar

I have a question regarding building and integrate my Java project. My source is located on BitBucket. Is there an online tool where I can build and install my Maven project? My goal is that the source on BitBucket is used and compiled. Afterwards it would be great to download the generated jar-file from the provider.
Thanks for your help,
Thomas
If your question is about online development
You can open your project in a Gitpod. It provides a full fledged editor and terminal wherein you can install dependencies and build your application. Has a bitbucket integration to directly port your code to the editor.
If your question is about continuous integration
You can add CI integration with BitBucket Pipelines or Circle CI to your application and write Jobs and Stages in a dedicated config file ( depending on your chosen CI tool ) to build, test and deploy your java application.

Selenium Automation Organize Project

I would like to automate few applications. This application consist of web, mobile (Android + IOS) and API. How to organize this project for this situation.
Im automation in selenium using Java. In C#, once can create a project consists of multiple sub projects. How to do it in Java?
Please advise.
A billion thanks for your help.
It depends on which build automation tool you choose to work with.
When you work with C# you probably use MSBuild
In Java Stack the most popular build automation tools are maven and gradle and both support multi-module projects, It is up to you to choose which one suits your project requirements.
See
Gradle vs. Maven
Multi-Module Project with Maven
Introduction to Gradle
Maven Scopes and Gradle Configurations Explained
I am not 100% sure what your goal is, but when it's about setting up Selenium (JAVA) projects and run them automatically, I can recommend you to use Maven & Jenkins to achieve this goal. Find further information in the following link:
https://www.guru99.com/maven-jenkins-with-selenium-complete-tutorial.html
I hope I could help.

Why exactly did you choose MAVEN for your selenium project

I was wondering what could be the good answer to "Why was the need to use Maven and Not Jenkins or other framework"
This is with respect to an automation project created in selenium and testNG with Maven framework
There are a couple of fundamental and functional difference between the usability of Maven and Jenkins
Maven :
Apache Maven popularly known as Maven is a Software Project Management tool. Based on the concept of a Project Object Model (POM), Maven can manage a project's build, reporting and documentation from a central piece of information dynamically which is configured through a file pom.xml.
From Selenium Framework perspective, Maven enables you to to get rid of the manual configuration of Selenium JARS and WebDrivers. You can easily switch over from one version of the underlying software to another through a simple update in pom.xml.
Jenkins :
Jenkins is a popular tool for Continous Integration (CI) which can be used as a simple CI server or turned into the continuous delivery hub for any project. Jenkins being a self-contained Java-based Program is always ready to run out-of-the-box with packages for Windows, Mac OSX and other Unix-like operating systems. Jenkins can be easily configured through its web interface to integrate on-the-fly check-ins and built-in help.
From Selenium Test Automation perspective, through Jenkins you would be able to schedule the Test Execution whenever you require and as many times you may require.

Appium Maven tests with Travis CI tool

I am kind of struggling with transitioning from Jenkins to Travis-CI. Running an Appium (or consider it Selenium) project that is built using Maven. I am not sure what really should go into the travis.yml file. From what I have been told I need to do a before_install, before_script, and script, and after (after not sure). Could someone please be nice of kind enough to paste a travis.yml that was created for Java Maven project.
Also not sure I will get the test running on a physical device for a tool that is hosted on the Cloud. For Jenkins all we would do is hook up the device to the master/slave.

Work on a remote Java source code with local Netbeans

I would like to run and test my new java application on my remote server but I want to work on it from my local Netbeans. How can I do ?
Thank you very much.
Best Regards.
Here is profesional solution from my company:
We use Jenkins for building java code in during a peroids called "jobs". Jenkins tests the application automatically (ex. JUnit tests). You can use GIT repository which is compatible with Jenkins, although I recommend Gerrit. And for NetBeans you can configure it to work with GIT repository, or install a plugin (Im not very familiar with Netbeans).

Categories

Resources