transit-taf-core
v1.0.39
Published
Transit Core Automation Framework
Downloads
810
Readme
transit-taf-core
This is a core repository which is exported as an npm package, used across different application test automation frameworks like ecolane, fasterlite, faster web, etc.
Installation
npm install transit-taf-coreImport Paths
The package provides specific import paths for better organization and tree-shaking:
Base UI Components
// Page Actions
import { BasePageActions } from 'transit-taf-core/baseui/actions';
// Page Validations
import { BasePageValidations } from 'transit-taf-core/baseui/validations';
// Page Waits
import { BasePageWaits } from 'transit-taf-core/baseui/waits';
// Common Actions
import { CommonPageActions } from 'transit-taf-core/baseui/common-actions';
// Common Validations
import { CommonPageValidations } from 'transit-taf-core/baseui/common-validations';
// Common Waits
import { CommonPageWaits } from 'transit-taf-core/baseui/common-waits';
// Logger
import { Logger } from 'transit-taf-core/baseui/logger';Base API Components
// API Helpers
import { BaseAPIHelpers } from 'transit-taf-core/baseapi/helpers';
// API Utils
import { APIUtils } from 'transit-taf-core/baseapi/utils';Utilities
// General Utils
import { getDate, getTime, getRandomPhoneNumber } from 'transit-taf-core/utils';
// Excel Utils
import { ExcelUtils } from 'transit-taf-core/utils/excel';
// TestRail Client
import { TestRailClient } from 'transit-taf-core/utils/testrail';
// TestRail Importer
import { uploadJunitToTestRail } from 'transit-taf-core/utils/testrail-importer';Test Data
// Test Data Loader
import { loadTestData, TestDataLoader } from 'transit-taf-core/test-data';Constants
// Test Tags
import { tags } from 'transit-taf-core/constants/tags';Reporters
// TestRail Reporter (Deprecated - use upload script instead)
import TestRailReporter from 'transit-taf-core/reporters/testrail';Scripts
For TestRail integration, use the standalone upload script in your test repository. See TestRail Integration Guide for detailed setup instructions.
// Import the upload functionality
import { uploadJunitToTestRail } from 'transit-taf-core/utils/testrail-importer';Fixtures
// Playwright Fixtures
import { test, expect } from 'transit-taf-core/fixtures';Default Import (All Exports)
If you need multiple imports, you can still use the default path:
import { BasePageActions, Logger, tags, getDate } from 'transit-taf-core';Building and Publishing
# Build the package
npm run build
# Publish to npm
npm publishDocumentation
- Quick Start Migration Guide
- Test Data Loader Guide
- TestRail Integration Guide - New! Learn how to integrate TestRail result uploads in your test repository
Usage in Other Projects
After installation, import the specific modules you need using the paths above. This approach provides:
- Better tree-shaking: Only import what you need
- Clear organization: Know exactly where each import comes from
- Type safety: Full TypeScript support with all imports
