{"id":26898441,"url":"https://github.com/jabercrombia/ada-e2e-testing","last_synced_at":"2025-06-15T16:01:59.872Z","repository":{"id":282929156,"uuid":"950117391","full_name":"jabercrombia/ADA-e2e-testing","owner":"jabercrombia","description":"Python testing to make sure site is ADA compliant","archived":false,"fork":false,"pushed_at":"2025-03-17T17:25:43.000Z","size":4,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T05:47:27.630Z","etag":null,"topics":["selenium","selenium-python"],"latest_commit_sha":null,"homepage":"","language":"Python","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/jabercrombia.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":"2025-03-17T16:53:00.000Z","updated_at":"2025-03-18T05:06:04.000Z","dependencies_parsed_at":"2025-03-17T18:28:58.981Z","dependency_job_id":"cd104b84-a652-4fc1-83fb-cf6c5b74330b","html_url":"https://github.com/jabercrombia/ADA-e2e-testing","commit_stats":null,"previous_names":["jabercrombia/ada-cypress-testing","jabercrombia/ada-e2e-testing"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jabercrombia%2FADA-e2e-testing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jabercrombia%2FADA-e2e-testing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jabercrombia%2FADA-e2e-testing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jabercrombia%2FADA-e2e-testing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jabercrombia","download_url":"https://codeload.github.com/jabercrombia/ADA-e2e-testing/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246591802,"owners_count":20801985,"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","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":["selenium","selenium-python"],"created_at":"2025-04-01T05:47:33.808Z","updated_at":"2025-04-01T05:47:34.725Z","avatar_url":"https://github.com/jabercrombia.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Python Webpage Alt Tag Test\n\n## Overview\nThis Python script uses Selenium to check if all `\u003cimg\u003e` tags on a webpage have `alt` attributes, improving accessibility and compliance with WCAG standards.\n\n## Prerequisites\n- **Python 3.x** installed\n- **Google Chrome** (or another browser)\n- **Chromedriver** (or appropriate WebDriver for your browser)\n- **Selenium** installed\n\n## Installation\n\n### 1. Install Python (if not already installed)\nIf Python is not installed, install it via Homebrew:\n```sh\nbrew install python\n```\n\n### 2. Install Selenium\nRun the following command:\n```sh\npython3 -m pip install selenium\n```\n\n### 3. Download the WebDriver\n- Download the appropriate WebDriver for your browser:\n  - **Chrome:** [ChromeDriver](https://sites.google.com/chromium.org/driver/)\n  - **Firefox:** [GeckoDriver](https://github.com/mozilla/geckodriver/releases)\n- Place it in your system `PATH` or specify its location in the script.\n\n## Running the Script\n\nSave the following script as `check_alt_tags.py`:\n\n```python\nfrom selenium import webdriver\nfrom selenium.webdriver.common.by import By\n\n# Replace with your webpage URL\nURL = \"https://www.exmaple.com\"\n\n# Set up Selenium WebDriver (Ensure chromedriver is in your PATH)\ndriver = webdriver.Chrome()\n\ndriver.get(URL)\n\n# Find all \u003cimg\u003e tags\nimages = driver.find_elements(By.TAG_NAME, \"img\")\n\n# Check for missing or empty alt attributes\nmissing_alt = []\nfor img in images:\n    alt_text = img.get_attribute(\"alt\")\n    if not alt_text:\n        missing_alt.append(img.get_attribute(\"src\"))\n\n# Output results\nif missing_alt:\n    print(\"❌ Images missing alt attributes:\")\n    for src in missing_alt:\n        print(f\"- {src}\")\nelse:\n    print(\"✅ All images have alt attributes!\")\n\n# Close the browser\ndriver.quit()\n```\n\n### Run the script:\n```sh\npython3 check_alt_tags.py\n```\n\n## Using a Virtual Environment (Recommended)\nInstead of installing system-wide dependencies, create a virtual environment:\n```sh\npython3 -m venv venv\nsource venv/bin/activate\npip install selenium\n```\nAfter use, deactivate it:\n```sh\ndeactivate\n```\n\n## Why This Test is Important\n**Enhances accessibility** – Helps visually impaired users using screen readers.\n**Improves SEO** – Search engines use alt text for indexing images.\n**Ensures compliance** – Meets WCAG and ADA accessibility standards.\n\n## Additional Resources\n- [Selenium Documentation](https://www.selenium.dev/documentation/)\n- [Web Content Accessibility Guidelines (WCAG)](https://www.w3.org/WAI/standards-guidelines/wcag/)\n- [Why Alt Text Matters](https://webaim.org/techniques/alttext/)\n\n## License\nThis project is licensed under the MIT License.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjabercrombia%2Fada-e2e-testing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjabercrombia%2Fada-e2e-testing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjabercrombia%2Fada-e2e-testing/lists"}