Skip to content

Instantly share code, notes, and snippets.

View zhabinskiy's full-sized avatar

Tino Zhabinskiy zhabinskiy

View GitHub Profile
@zhabinskiy
zhabinskiy / laravel-livewire-test.php
Last active July 14, 2021 21:41
Laravel Livewire test example
<?php
namespace Tests\Feature;
use App\User;
use Tests\TestCase;
use Livewire\Livewire;
use Illuminate\Support\Facades\Route;
use Illuminate\Foundation\Testing\RefreshDatabase;
@zhabinskiy
zhabinskiy / index.test.jsx
Created June 15, 2018 07:58
Jest + Enzyme example from one of my recent projects
import React from 'react';
import { StaticRouter } from 'react-router';
import 'jest-styled-components';
import renderer from 'react-test-renderer';
import { configure, mount } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
/* Redux */
import { createStore } from 'redux';
import { Provider } from 'react-redux';