{"id":13482719,"url":"https://github.com/thingsinjars/Hardy","last_synced_at":"2025-03-27T13:32:33.515Z","repository":{"id":5708183,"uuid":"6919024","full_name":"thingsinjars/Hardy","owner":"thingsinjars","description":"Selenium-driven, cucumber-powered CSS testing.","archived":false,"fork":false,"pushed_at":"2015-03-27T13:13:54.000Z","size":42985,"stargazers_count":321,"open_issues_count":10,"forks_count":27,"subscribers_count":18,"default_branch":"master","last_synced_at":"2024-04-09T21:50:55.631Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://hardy.io/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thingsinjars.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-11-29T10:21:34.000Z","updated_at":"2024-01-21T22:53:57.000Z","dependencies_parsed_at":"2022-08-25T06:01:40.946Z","dependency_job_id":null,"html_url":"https://github.com/thingsinjars/Hardy","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thingsinjars%2FHardy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thingsinjars%2FHardy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thingsinjars%2FHardy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thingsinjars%2FHardy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thingsinjars","download_url":"https://codeload.github.com/thingsinjars/Hardy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":222262452,"owners_count":16957584,"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":[],"created_at":"2024-07-31T17:01:04.839Z","updated_at":"2024-10-30T16:31:37.873Z","avatar_url":"https://github.com/thingsinjars.png","language":"JavaScript","funding_links":[],"categories":["JavaScript","Tools and frameworks","Tools and frameworks (a-z↓)"],"sub_categories":[],"readme":"[Hardy](http://hardy.io/)\n===\n\n(The Not-quite-ready-yet release)\n---\n\n_This is almost entirely working but not 100%. If you spot a problem, please [file an issue](https://github.com/thingsinjars/Hardy/issues)._\n\n[Hardy](http://hardy.io/) is a collection of CSS testing steps and a boilerplate testing setup to get you up-and-running with automated CSS testing as quickly as possible. Tests are written in Cucumber and use Selenium. Hardy runs on Node.js and therefore all the example CSS test helpers are written in JS. The functionality behind them can easily be reused in any test setup, whether your tests are written in Java, Ruby or anything else.\n\nThis is a refactor of the original GhostStory project to run against Selenium using WebDriverIO. The original collection of CSS testing steps were written specifically for CasperJS and PhantomJS but now that PhantomJS supports the WebDriver protocol, we're now going via Selenium so that tests can be run against any browser.\n\nThe structure of this project and the WebDriverIO bindings are from [WebDriverIO](https://github.com/webdriverio/webdriverio).\n\n![image](https://raw.github.com/thingsinjars/hardy.io/94b2744df96f17020ba17bfcf279ba52907a4abf/assets/small-logo.png)\n\nRead more at [Hardy.io](http://hardy.io/).\n\nInstallation\n---\n\nThe recommended way to install Hardy is via [npm](https://npmjs.org/):\n\n    npm install -g hardy\n\nThis will install Hardy as a global node module and put an executable `hardy` in your path. It will also include a local version of [Selenium v2.32.0]((http://docs.seleniumhq.org/) in case you don't have that already and a local copy of [PhantomJS v1.9.0]((http://phantomjs.org/)) for image diff test processing.\n\n_NOTE: Currently, the local install of PhantomJS will not be available for testing against unless you add it to your path._\n\nFor best results, you'll also need a Selenium–capable browser. Firefox supports the WebDriver protocol by default so without specifying otherwise, tests will be run against Firefox. [PhantomJS](http://phantomjs.org/) also supports WebDriver.\n\nTo run tests against Chrome, you will need to install [ChromeDriver](https://code.google.com/p/selenium/wiki/ChromeDriver).\n\nTo run tests against Internet Explorer, you will need [InternetExplorerDriver](https://code.google.com/p/selenium/wiki/InternetExplorerDriver).\n\nTo run Selenium at all, you'll need [Java](http://java.com/en/download/index.jsp).\n\nFinally, for (significantly) faster visual image compares, install GraphicsMagick.  On OSX:\n\n    brew install graphicsmagick\n\nGetting started\n---\n\nFor full details on how to get started with Hardy, check out the documentation at [hardy.io](http://hardy.io/)\n\nCommands / usage\n---\n\n    hardy init\n      initialises an empty test directory\n\n    hardy selenium start\n      starts the local selenium server (essential before tests)\n\n    hardy selenium stop\n      stops the local selenium server\n\n    hardy .\n      run all the tests in the current folder with the default browser (Firefox)\n\n    hardy --browser=phantomjs .\n      specify the browser to test with\n\n    hardy --browser=phantomjs,chrome .\n      specify multiple browsers to test with\n\nTests\n---\n\nTo verify Hardy is working as it should, unit and acceptance tests are available. They can be run via [Grunt](http://gruntjs.com/) from the project root:\n\n    grunt unit\n    grunt acceptance\n\n    # Or, to run both:\n    grunt test\n\nThe tests are automatically run on every commit to the main repo. Currently building on Travis CI:\n\n[![Build Status](https://travis-ci.org/thingsinjars/Hardy.png)](https://travis-ci.org/thingsinjars/Hardy)\n\nTravis Integration\n---\n\nTo include Hardy in a Travis CI pipeline, import it as a devDependency:\n\n    npm install --save-dev hardy\n\nAdd the following to your .travis.yml:\n\n    before_script:\n      - export DISPLAY=:99.0\n      - sh -e /etc/init.d/xvfb start\n      - node_modules/hardy/bin/hardy selenium start\n      - {BUILD YOUR STATIC SITE HERE}\n      - python -m SimpleHTTPServer\u0026\n\nAnd finally, add this to your package.json `scripts` object:\n\n    \"scripts\": {\n      \"test\": \"node_modules/hardy/bin/hardy --browser=firefox,phantom \u003cPATH TO YOUR TEST FOLDER\u003e\"\n    },\n\nFor more detail, read the [continuous integration guide on the Hardy site](http://hardy.io/continuous-integration.html).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthingsinjars%2FHardy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthingsinjars%2FHardy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthingsinjars%2FHardy/lists"}