PHPackages                             unglud/dusker - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. unglud/dusker

AbandonedLibrary[Testing &amp; Quality](/categories/testing)

unglud/dusker
=============

Stand alone Laravel Dusk test suit, which do not require Laravel framework itself.

v2.1.1(8y ago)331.5k2[1 PRs](https://github.com/unglud/dusker/pulls)MITPHPPHP &gt;=7.0

Since Nov 3Pushed 6y ago3 watchersCompare

[ Source](https://github.com/unglud/dusker)[ Packagist](https://packagist.org/packages/unglud/dusker)[ RSS](/packages/unglud-dusker/feed)WikiDiscussions master Synced yesterday

READMEChangelog (4)Dependencies (13)Versions (5)Used By (0)

dusker
======

[](#dusker)

Stand-alone Laravel Dusk test suit, which does not require Laravel framework itself.

[![Build Status](https://camo.githubusercontent.com/881d6bd039b4783ddd93cabe6667abc5fcd88b7c9917da9f415a8b8dd759ba12/68747470733a2f2f7472617669732d63692e6f72672f756e676c75642f6475736b65722e737667)](https://travis-ci.org/laravel/dusk)[![Total Downloads](https://camo.githubusercontent.com/c7ab8978ce6b204f9558b410fc226d684217c31b76f330386b27ddc477175e22/68747470733a2f2f706f7365722e707567782e6f72672f756e676c75642f6475736b65722f642f746f74616c2e737667)](https://packagist.org/packages/unglud/dusker)[![Latest Stable Version](https://camo.githubusercontent.com/a3b44d645b69adf4e87c428b3e7c4f8da535f6f7811185452288a4e202f48c50/68747470733a2f2f706f7365722e707567782e6f72672f756e676c75642f6475736b65722f762f737461626c652e737667)](https://packagist.org/packages/unglud/dusker)[![License](https://camo.githubusercontent.com/2e4e213db08f2e3fa8ff09427f1ef96d7f2095aa5121585afa236b904ca3e65f/68747470733a2f2f706f7365722e707567782e6f72672f756e676c75642f6475736b65722f6c6963656e73652e737667)](https://packagist.org/packages/unglud/dusker)

[![](https://camo.githubusercontent.com/2412744304860c125827160c9e585c7f7ac8f07496671794f829c68761b900de/68747470733a2f2f6c61726176656c2e636f6d2f6173736574732f696d672f636f6d706f6e656e74732f6c6f676f2d6475736b2e737667)](https://camo.githubusercontent.com/2412744304860c125827160c9e585c7f7ac8f07496671794f829c68761b900de/68747470733a2f2f6c61726176656c2e636f6d2f6173736574732f696d672f636f6d706f6e656e74732f6c6f676f2d6475736b2e737667)

[Laravel Dusk](https://github.com/laravel/dusk) provides an expressive, easy-to-use browser automation and testing API. By default, Dusk does not require you to install JDK or Selenium on your machine. Instead, Dusk uses a standalone Chrome driver. However, you are free to utilize any other Selenium driver you wish.

Installation
------------

[](#installation)

To get started, you should add the unglud/dusker Composer dependency to your project:

```
composer require --dev unglud/dusker

```

Next, you need to copy all necessary files to your working directory. The command below will do it for you. It creates (or use existing) `tests` directory and put files there. Also, it copies `artisan` console utility to your project root directory. **If you already have this file, it will be overwritten!**

The file `.env.dusk` will be in your project root as well, which you will need rename to `.env` or copy it content to your existing one.

```
composer run-script post-install-cmd -d ./vendor/unglud/dusker

```

If you would like these files to update automatically each time you update this package, you can add this to your `composer.json` file:

```
"scripts": {
  "post-install-cmd": [
    "Dusker\\CopyFile::copy"
  ],
  "post-update-cmd": [
    "Dusker\\CopyFile::copy"
  ]
},
"extra": {
  "copy-file": {
    "vendor/unglud/dusker/src/example/": "tests/",
    "vendor/unglud/dusker/artisan": "artisan"
  }
}

```

As you notice file `.env.dusk` not included there to simplify things.

After installing the package, Artisan commands will be available from your root project. Run the `dusk:install` Artisan command:

```
php artisan dusk:install

```

Now try to run test to make sure everything works

```
php artisan dusk

```

How to use
----------

[](#how-to-use)

After this part you can use official documentation for Dusk on the [Laravel website](https://laravel.com/docs/master/dusk), `cuz it will work exactly as it was designed by [Taylor Otwell](https://github.com/taylorotwell).

Authentication
--------------

[](#authentication)

Often, you will be testing pages that require authentication. You can use Dusk's loginAs method in order to avoid interacting with the login screen during every test. The loginAs method accepts a user `login` and `password`:

```
$this->browse(function (Browser $browser) {
    $browser->loginAs('username', 'password')
          ->visit('/home');
});

```

After using the loginAs method, the user session will be maintained for all tests within the file.

### Authentication Setup

[](#authentication-setup)

Since we do not have access to native `Auth` and `Router` from Laravel, because we use it without Laravel we need to setup login functionality. In `.env` you should specify `LOGIN_ENDPOINT` -- path to your public directory where Dusker will copy the file which will be accessible from a browser. By default its `http://example.com/_dusker/login.php`. Second `LOGIN_IMPLEMENTATION` -- path to your class, which utilize logic of your project allowing Authentication. You can use `/tests/LoginManagerExample.php` as an example of how it should look.

License
-------

[](#license)

Dusker is released under the MIT Licence. See the bundled [LICENSE](https://github.com/unglud/dusker/blob/master/LICENSE) file for details.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

4

Last Release

3107d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0b85dea7921dfab50a27316ef0644ec31206302e9cb6c08557802ac4e7ea1632?d=identicon)[unglued](/maintainers/unglued)

---

Top Contributors

[![unglud](https://avatars.githubusercontent.com/u/1012620?v=4)](https://github.com/unglud "unglud (5 commits)")

---

Tags

chromedriverduskintegration-testinglaravelphpunitseleniumtestinglaravelwebdriver

### Embed Badge

![Health badge](/badges/unglud-dusker/health.svg)

```
[![Health](https://phpackages.com/badges/unglud-dusker/health.svg)](https://phpackages.com/packages/unglud-dusker)
```

###  Alternatives

[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k39.1M32.1k](/packages/orchestra-testbench)[laravel-zero/framework

The Laravel Zero Framework.

3371.4M369](/packages/laravel-zero-framework)[laravel/dusk

Laravel Dusk provides simple end-to-end testing and browser automation.

1.9k36.7M259](/packages/laravel-dusk)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

255.2k](/packages/aedart-athenaeum)[unisharp/laravel-filemanager

A file upload/editor intended for use with Laravel 5 to 10 and CKEditor / TinyMCE

2.2k3.3M74](/packages/unisharp-laravel-filemanager)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
