定制 nmfzone/laravel-behat-dusk 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

nmfzone/laravel-behat-dusk

Composer 安装命令:

composer require nmfzone/laravel-behat-dusk

包简介

Seamlessly integrate Behat with Laravel Dusk

README 文档

README

Laravel Behat Dusk

Build Status Total Downloads Latest Stable Version License

Introduction

Seamlessly integrate Behat with Laravel Dusk.

Requirements

  • PHP >= 7.1

Installation

$ composer require nmfzone/laravel-behat-dusk

If you want to change the default config, you must publish the config file:

$ php artisan vendor:publish --provider="Nmflabs\LaravelBehatDusk\ServiceProvider"

Usage

I assume you're using this package for the first time you setup behat (so there is no behat.yml, etc).

  1. Run this command php artisan behat-dusk:install
  2. Duplicate your .env to .env.behat (optional). This will be the environment used by behat.
  3. Adjust behat.yml as you wish
  4. To run the test, run this command php artisan behat (it's just wrapper of the original behat command. It's automatically run php artisan serve for you, and stop it when test is done 🔥)
  5. Enjoy!

Troubleshooting

  1. Element is not clickable at (x, y)

    If you're experiencing this issue, there is a high possibility that you're clicking an element that outside the viewport.

    What does it means? It means your element isn't appears on your screen (maybe your element located in very bottom of the page), when the browser trying to click that element. So, of course it's impossible to click that element.

    In the real usage, you're just scrolling the browser to bottom, until you see your element, right? Then, it's just the same here. You need to tell the browser, to scroll the browser to bottom, until it found the element.

    public function selectCheckbox($selector)
    {
        $this->browse(function (Browser $browser) use ($selector) {
            $browser->scrollTo('#foo-element')->check($selector);
        });    
    }

Security

If you discover any security related issues, please email to 123.nabil.dev@gmail.com instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 2.24k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 8
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 7
  • Watchers: 1
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-11-16

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固