Skip to content

Instantly share code, notes, and snippets.

View venkata-qa's full-sized avatar

Venkata Koripalli venkata-qa

  • QAWORKFORCE LTD
  • Leeds, United Kingdom
View GitHub Profile
#!/bin/bash
# Ensure a namespace is provided
NAMESPACE=$1
if [[ -z "$NAMESPACE" ]]; then
echo "❌ Usage: $0 <namespace>"
exit 1
fi
REPORT_FILE="k8s_namespace_report.txt"
#!/bin/bash
# Ensure a namespace is provided
NAMESPACE=$1
if [[ -z "$NAMESPACE" ]]; then
echo "❌ Usage: $0 <namespace>"
exit 1
fi
REPORT_FILE="k8s_namespace_report.txt"
public static void waitAndClick(WebDriver driver, By locator, int timeout) {
try {
// Create a WebDriverWait instance with the specified timeout
WebDriverWait wait = new WebDriverWait(driver, Duration.ofSeconds(timeout));
// Wait until the element is clickable
WebElement element = wait.until(ExpectedConditions.elementToBeClickable(locator));
// Click the element
element.click();
@venkata-qa
venkata-qa / .txt
Created January 28, 2025 17:16
linux-commands
# To count the entries based on the text
grep -E "POST|GET" logfilename | wc -l
@venkata-qa
venkata-qa / gpg-key-migration.md
Created August 16, 2023 09:44 — forked from angela-d/gpg-key-migration.md
Move GPG Keys from One Machine to Another

Migrate GPG Keys from One Workstation to Another

Replace [your key] with your key ID

To obtain your key ID

gpg --list-secret-keys --keyid-format LONG

Which returns something like

@venkata-qa
venkata-qa / CustomSimulation.scala
Created April 18, 2023 23:23 — forked from mburrows02/CustomSimulation.scala
Gatling simulation with dynamic scenarios and injection profiles
package test
import io.gatling.core.Predef._
import io.gatling.core.structure.PopulatedScenarioBuilder
import io.gatling.core.controller.inject.InjectionStep
import io.gatling.http.Predef._
import io.gatling.jdbc.Predef._
import scala.concurrent.duration._
import scala.collection.mutable.ArraySeq
import org.json.JSONArray;
import org.json.JSONObject;
@venkata-qa
venkata-qa / README.md
Created February 1, 2022 17:17 — forked from jmruc/README.md
Generating pom.xml from gradle

To generate a pom.xml file just run gradle writeNewPom

If you want to generate it as pom.xml in the root of the project, replace writeTo("$buildDir/newpom.xml") with writeTo("pom.xml")

###########################################################################################################################
# How to set or change the default Java (JDK) version on macOS?
Run the command /usr/libexec/java_home -V to output the installed versions
Example output
Matching Java Virtual Machines (3):
1.8.0_05, x86_64: "Java SE 8" /Library/Java/JavaVirtualMachines/jdk1.8.0_05.jdk/Contents/Home
1.6.0_65-b14-462, x86_64: "Java SE 6" /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
1.6.0_65-b14-462, i386: "Java SE 6" /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
Pick the version you want to be the default from the above list
#Error: Java: invalid target release: 11 - IntelliJ IDEA
Resolution:
File->Project Structure->Modules ->> Language level to 8 ( my maven project was set to 1.8 java)
File -> Settings -> Build, Execution, Deployment -> Compiler -> Java Compiler -> 8 also there
#To find the latest dependecies update of the project
mvn versions:display-dependency-updates
#To check the plugin updates
mvn versions:display-plugin-updates
#To use latest versions
mvn versions:use-latest-versions
https://www.baeldung.com/maven-force-update