{"id":21523210,"url":"https://github.com/testcentricity/tc_web_sample","last_synced_at":"2025-10-08T17:14:17.463Z","repository":{"id":32037830,"uuid":"128572092","full_name":"TestCentricity/tc_web_sample","owner":"TestCentricity","description":"A sample test suite and framework that utilizes the TestCentricity™ web gem","archived":false,"fork":false,"pushed_at":"2023-12-22T18:20:39.000Z","size":37090,"stargazers_count":1,"open_issues_count":2,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-03-17T17:49:45.185Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TestCentricity.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-04-07T21:58:48.000Z","updated_at":"2022-02-28T19:01:20.000Z","dependencies_parsed_at":"2025-03-17T22:47:45.313Z","dependency_job_id":null,"html_url":"https://github.com/TestCentricity/tc_web_sample","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TestCentricity/tc_web_sample","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TestCentricity%2Ftc_web_sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TestCentricity%2Ftc_web_sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TestCentricity%2Ftc_web_sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TestCentricity%2Ftc_web_sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TestCentricity","download_url":"https://codeload.github.com/TestCentricity/tc_web_sample/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TestCentricity%2Ftc_web_sample/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278981518,"owners_count":26079640,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-24T01:12:59.462Z","updated_at":"2025-10-08T17:14:17.447Z","avatar_url":"https://github.com/TestCentricity.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tc_web_sample\n\nThis is a Cucumber based sample test suite and framework utilizing the TestCentricity™ gem and a page-object model architecture\nfor desktop and responsive mobile web functional testing of the UAL Flight Booking web portal. This project includes examples of\nexternally sourcing test data from an Excel `.xls`, a `.yml` or a `.json` data file.\n\nDetailed HTML documentation for this project can be accessed by opening `/tc_web_sample/doc/index.html` in a web browser (after\ndownloading or cloning from the Github [repository](https://github.com/TestCentricity/tc_web_sample.git)).\n\n\n## Gem Dependencies:\n\ncucumber  [![Gem Version](https://badge.fury.io/rb/cucumber.svg)](https://badge.fury.io/rb/cucumber)\n\ncapybara  [![Gem Version](https://badge.fury.io/rb/capybara.svg)](https://badge.fury.io/rb/capybara)\n\ntestcentricity_web  [![Gem Version](https://badge.fury.io/rb/testcentricity_web.svg)](https://badge.fury.io/rb/testcentricity_web)\n\n\n## Supporting Documentation\n\n[TestCentricity Framework for Web - testcentricity_web gem](https://rubygems.org/gems/testcentricity_web)\n\n[TestCentricityWeb - documentation](http://www.rubydoc.info/gems/testcentricity_web/)\n\n\n\n## Prerequisites to running tests:\n\nIn order for Cucumber to execute features or scenarios from the `tc_web_sample` test automation project, a minimum of 3 conditions\nmust be specified in the Cucumber command line at runtime. These conditions include `target_test_environment`, `target_browser`, and\n`test_context`.\n\n### `target_test_environment`:\n\nAutomated tests may be targeted at one of 2 test environments. Those test environments are:\n\n| **Value** | **Description**        |\n|-----------|------------------------|\n| `qa`      | QA environment         |\n| `prod`    | PRODUCTION environment |\n\n**NOTE:**  Both environments point to the same UAL Booking portal at http://www.united.com/ual/\n\n\n### `test_context`:\n\nAutomated tests may be targeted at one of 4 test contexts. Those test contexts are:\n\n| **Value** | **Description**                                                                                                                                                       |\n|-----------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `bat`     | Run only features/scenarios with `@bat` tag to execute a Build Acceptance Test suite                                                                                  |\n| `regress` | Run all features/scenarios with `@regression` tag to execute a comprehensive Regression test suite                                                                    |\n| `dev`     | Run only features/scenarios with `@dev` tag. Used to run only those features/scenarios that are tagged with `@dev`, are actively under development or being debugged. |\n| `wip`     | Run only features/scenarios with `@wip` tag  (work in progress)                                                                                                       |\n\n### `target_browser`:\n\nAutomated tests may be targeted at one of 5 supported desktop web browsers, which must already be locally installed on your test\nworkstation. Supported desktop browsers are:\n\n| **Value** | **Description** |\n|-----------|-----------------|\n| `chrome`  | OS X or Windows |\n| `firefox` | OS X or Windows |\n| `edge`    | OS X or Windows |\n| `safari`  | OS X only       |\n| `ie`      | Windows only    |\n\nAutomated tests may also be executed on desktop browsers (Chrome, Edge, or Firefox) hosted on Selenium Grid 4 or Dockerized Selenium\nGrid 4 environments. See instructions below.\n\nAutomated tests may also be targeted to run on cloud hosted desktop or mobile web browsers using using the following service:\n* [Browserstack](https://www.browserstack.com/list-of-browsers-and-platforms?product=automate)\n* [Sauce Labs](https://saucelabs.com/open-source#automated-testing-platform)\n* [TestingBot](https://testingbot.com/features)\n* [LambdaTest](https://www.lambdatest.com/selenium-automation)\n\nRefer to the [Remote cloud hosted desktop and mobile web browsers](https://www.rubydoc.info/gems/testcentricity_web/#remote-cloud-hosted-desktop-and-mobile-web-browsers) section\nof the TestCentricity gem documentation.\n\n\n## Instructions for running tests sequentially:\n\nThese instruction are for the sequential execution of features/scenarios. Tests will be executed within a single browser instance.\n\n1. Launch RubyMine, select the File/Open... menu item, navigate to the `tc_web_sample` folder on your computer, and click the OK\nbutton to open the `tc_web_sample` project.\n\n2. Open the Terminal window by selecting the View/Tool Windows/Terminal menu item.\n\n3. Select values from above for the `target_test_environment`, `target_browser`, and `test_context` command line parameters.\n\n4. To run Cucumber, execute the following command in the Terminal:\n\n        bundle exec cucumber -p target_test_environment -p target_browser -p test_context\n  \n    **NOTE:**\n      * To have Cucumber generate HTML formatted test results, append `-p report` to the above command line arguments.\n      * If you are running tests against mobile web browsers, you can override the default screen orientation of the mobile device\n      by appending `-p landscape` or `-p portrait` to the above command line arguments.\n\n    For example, to execute the entire regression suite against the QA environment on a locally hosted Chrome browser, with test\n    results being logged to an HTML test results file, execute the following command in the Terminal:\n    \n        bundle exec cucumber -p qa -p chrome -p regress -p report\n\n    To execute the regression suite against the QA environment on a locally hosted Firefox browser, with test results being logged\n    to an HTML test results file, execute the following command in the Terminal:\n    \n        bundle exec cucumber -p qa -p firefox -p regress -p report\n    \n    To execute the Build Acceptance Test suite against the PROD environment on a Chrome browser hosted on Selenium Grid 4 or\n    Dockerized Selenium Grid 4 environments, include `-p grid` in the command line, as in the following command:\n    \n        bundle exec cucumber -p prod -p bat -p chrome -p grid\n\n    To execute the Build Acceptance Test suite against the PROD environment on a locally emulated iPad Pro 12.9\" Mobile Safari web\n    browser in Portrait orientation, execute the following command in the Terminal:\n    \n        bundle exec cucumber -p prod -p ipad_pro_12_9 -p portrait -p bat\n\n    The following command specifies that Cucumber will run the Build Acceptance Test suite in the QA environment on an XCode\n    Simulator against an iPad Pro (12.9-inch) (5th generation) with iOS version 15.4 in landscape orientation:\n\n        bundle exec cucumber -p qa -p bat -p ipad_pro_12_15_sim -p landscape\n\n    **NOTE:** Appium must be running prior to executing this command. You can ensure that Appium Server is running by including `-p run_appium`\n    in your command line:\n\n        bundle exec cucumber -p qa -p bat -p ipad_pro_12_15_sim -p landscape -p run_appium\n\n\n6. As the Cucumber tests are executing, the Terminal will display the lines of each feature file and scenario as they run in real-time.\n\n7. Upon completion of test execution, the Terminal will display the final test results.\n\n8. If you specified in the command line that HTML formatted test results should be generated (`-p report`), you can view them by\nopening the `reports` folder in the `tc_web_sample` project directory, and selecting the `test_results.html` file. Right-clicking\non the `test_results.html` file will display a popup menu. Select the **Open in Browser** menu item, and then select a web browser\nfrom the popup sub menu that appears. The formatted test results will open in the web browser that you selected.\n\n\n## Instructions for running tests concurrently (parallel test execution)\n\nThese instruction are for the concurrent execution of features/scenarios, which reduces total test execution time by executing\nfeature/scenarios in parallel across multiple browser instances.\n\n1. Launch RubyMine, select the File/Open... menu item, navigate to the `tc_web_sample` folder on your computer, and click the OK\nbutton to open the `tc_web_sample` project.\n\n2. Open the Terminal window by selecting the View/Tool Windows/Terminal menu item.\n\n3. Select values from above for the `target_test_environment`, `target_browser`, and `test_context` command line parameters.\n\n4. To run Cucumber tests in a specific test context, execute the following command in the Terminal:\n\n        bundle exec parallel_cucumber features/ -o \"-p parallel -p target_test_environment -p target_browser -p test_context\"\n\n    **NOTE:** If you are running tests against mobile web browsers, you can specify the screen orientation of the mobile device\n    by including `-p landscape` or `-p portrait` to the above command line argument. For example, to execute the entire regression\n    suite against the QA environment on multiple locally emulated iPad Pro Mobile Safari web browsers in Portrait orientation,\n    execute the following command in the Terminal:\n\n        bundle exec parallel_cucumber features/ -o \"-p parallel -p qa -p regress -p ipad_pro_12_9 -p portrait\"\n\n    To execute the regression suite against the QA environment on multiple locally hosted Firefox web browsers, execute the\n    following command in the Terminal:\n\n        bundle exec parallel_cucumber features/ -o \"-p parallel -p qa -p regress -p firefox\"\n\n5. As your Cucumber tests are executing, the Terminal window will display the lines of each feature file and scenario as they\nrun in real-time.\n\n6. Upon completion of test execution, multiple HTML formatted test results can be reviewed by opening the `reports` folder in\nthe `tc_web_sample` project, and selecting and opening each of the `test_results.html` files individually.\n\n\n## Detailed Documentation\n\nDetailed HTML documentation of the features, scenarios, step definitions, classes, and methods for the `tc_web_sample` project can\nbe accessed from the `index.html` file within the `doc` folder in the `tc_web_sample` project folder:\n\n    tc_web_sample\n        ├── config\n        ├── doc\n        │   └── index.html\n        ├── features\n        └── reports\n\nTo view this documentation, navigate to the `index.html` file, right click on it, and select *Open in Browser*","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftestcentricity%2Ftc_web_sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftestcentricity%2Ftc_web_sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftestcentricity%2Ftc_web_sample/lists"}