Skip to content

Instantly share code, notes, and snippets.

View Kashifbaigqa's full-sized avatar

Kashif Baig Kashifbaigqa

View GitHub Profile
@Kashifbaigqa
Kashifbaigqa / log4j2.xml
Created March 28, 2026 12:27
Added sample Log4j2 configuration to log output to console and files. General logs are stored in app.log, while ERROR/FATAL logs are separately captured in error.log using threshold filters.
<?xml version="1.0" encoding="UTF-8"?>
<configuration status="WARN">
<appenders>
<!-- Console Appender -->
<console name="Console" target="SYSTEM_OUT">
<patternlayout pattern="%d{yyyy-MM-dd HH:mm:ss} [%t] %-5level %C{1} - %msg%n" />
</console>
<!-- General File Appender -->
<file name="FileLogger" filename="logs/app.log" append="true">
@Kashifbaigqa
Kashifbaigqa / ActionDriver.java
Created March 26, 2026 18:58
Sample ActionDriver class utility
package com.orangehrm.actiondriver;
import java.time.Duration;
import org.openqa.selenium.By;
import org.openqa.selenium.JavascriptExecutor;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.ui.ExpectedConditions;
import org.openqa.selenium.support.ui.WebDriverWait;
@Kashifbaigqa
Kashifbaigqa / gitignoreforselenium.txt
Last active July 1, 2026 15:35
Sample .gitignore file content for salenium data driven framework using java, maven, eclipse..
# Eclipse
.classpath
.project
.settings/
.metadata
bin/
tmp/
*.tmp
*.bak
@Kashifbaigqa
Kashifbaigqa / testng-multi-suite-example.xml
Created March 26, 2026 17:36
Sample TestNG XML configuration with multiple test groups and classes (suite → test → classes structure, parallel execution)
<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
<suite name="OrangeHRM Suite" parallel="tests" thread-count="2">
<!-- Test 1 -->
<test name="Login Tests">
<classes>
<class name="com.orangehrm.tests.LoginTest"/>
<class name="com.orangehrm.tests.InvalidLoginTest"/>
</classes>