I have started a new project and have a few regression tests written using Karate (more will be added with new features). I also have an automated build on Jenkins that runs this regression suite on an AWS instance. I would like to have a profiler run and provide a report while these tests are running so that I can identify hotspots and (potential) issues with each new submission of code and address it sooner rather than later. Is there something provided in AWS that can achieve this for me, or can it be done through Jenkins?
JProfiler has ant and Gradle plugins that can be used for automating profiling sessions and also for extracting reports from the saved snapshots.
You can use these plugins with Jenkins via its own ant or Gradle plugins.
Disclaimer: My company develops JProfiler.
Related
Problem Statement
Development project: nodejs
unit tests: available
Automation project: java
Problem: for our development project we already have unit test coverage. But to figure out automation coverage, we require a medium of instrumenting nodejs code (deployed on some env) while running autotests.
Need hints on how to achieve same? Have worked already on jacoco with both development and automation codes in java. Jacoco instruments flow while code is deployed and helps in providing various dump mechanism.
Solution:
Use a code coverage tool for Node.js such as Istanbul, NYC or Jest to instrument the code and collect coverage information during test runs.
Export the coverage data in a format that can be used by other tools for analysis and reporting.
Integrate the coverage data with your existing Jacoco tool to have a unified coverage report for both development and automation projects.
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.
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.
I am working on augmenting a test framework that uses Maven. Due to the nature of the code being tested, it is necessary to run tests in VMs. We are currently doing this in a sort of hack-ish way by running shell scripts that SSH into the VMs via Vagrant and run a list of tests. However, this list of tests has to be updated every time someone adds a new integration test to our tests. Ideally, we'd like to automatically gather the relevant tests that are flagged as Component / Integration tests with #Category JUnit flags in our Java code, and then run these tests within the VMs. It seems like Failsafe has no parameters to run the integration tests outside of the local machine. Is there any way to do this using existing Maven plugins?
Ideally, the flow of things would be as follows:
Discover all component / integration tests using Failsafe.
Pass the list of these tests into a VM
Run the tests on that VM, preferably with vagrant.
The existing plugin for Vagrant in Maven shows how to run a VM during integration tests, but it doesn't make clear how to actually run the integration tests on the VMs within Maven: http://nicoulaj.github.io/vagrant-maven-plugin/examples/running-a-vm-during-integration-tests.html . The plugin hasn't been updated since 2013 either, which isn't very promising.
I'm looking for a complete java development infrastructure with an integration of:
an IDE like eclipse,
a build system like Maven,
a version control system like subversion,
a continuous integration server like Hudson,
a repository manager like Nexus,
an automated release plugin like Maven Release Plugin.
Further I'd like to have:
a predefined multi component project structure
...and optionally:
an issue manager like Jira,
an integration with an open source hoster like sourceforge.
Evaluating all these systems could take a long time, making the setup of a running infrastructure a job of a month or longer.
At work I'm ready to setup each system individually, but for my private development at home I'd like to have something like Devware - A development environment virtual appliance (unfortunately I didn't find a download link) where everything is already installed and functional.
So, could you please give me some advice which combinations create a working infrastructure? Or even better where to find a preconfigured development infrastructure?
PS: I'm not committed to any of the named products, so feel free to suggest alternatives if they match better.
If you're looking to avoid some integration pains, check out SecureCI, which is a free download of various open-source products in an integrated stack.
Blurb from the site:
SecureCIā¢ provides organizations with an integrated suite of open source tools that assist in the automation of the software build, test, and deploy process. By integrating secure code analysis and web security testing technologies, SecureCI extends continuous integration to incorporate automated security analysis and security testing of applications as well.
The current version bundles these tools:
Project Management
Trac (0.11.5)
Sonar (1.10.1)
Security Scanning
ratproxy (1.58)
Development
Subversion (1.4.6)
Hudson (1.322)
Apache Ant (1.7.1)
Apache Maven (2.2.1)
Sonatype Nexus (1.3.6)
Testing
JUnit (4.6)
Cobertura (1.9.2)
Selenium Remote Control (1.0.1)
Code Analysis
Checkstyle (5.0)
FindBugs (1.3.8)
PMD (4.2.5)
JDepend (2.9)
As far as IDE integrations are concerned, later versions of Eclipse now come integrated with Mylyn, this provides a task focused API for connecting to various tools.
The Trac integration can be installed with the Connector Install Wizard.
Other Eclipse integrations to use:
Subversion integration: Subclipse and the Subclipse Mylyn integration)
Hudson plugin
Maven integration: M2Eclipse (also has some Mylyn connectors)
Code Coverage: ECLEmma (I find the Cobertura plugin doesn't work too well myself)
Selenium plugin
Checkstyle plugin
Findbugs plugin
PMD plugin
JDepend plugin or CAP
Or just use IntelliJ from JetBrains.
You might want to look into http://www.poweredbypulse.com. It provides easy to install pre-configured Eclipse instances. You can also build/configure your own.
It has been a while since I actually used this so it may have changed since then.