Laravel TestTools chrome extension

Laravel TestTools

Create Laravel integration tests while surfing your website.

Testing a Laravel application really is an easy task – the “Integrated” package from Jeffrey Way, that later got merged into the core framework is fantastic and helps you with the otherwise cumbersome task of testing and interacting with your application. But still – are you actually using tests?

A lot of times people really love the idea of tests, but simply don’t get their asses up to start using them in their own projects. That’s why I created a chrome extension that hopefully saves you some time when you need to test your app.

Get the extension

Using the chrome extension

The chrome extension allows you to “record” your activity on the page you’re currently viewing and translates these activies into Laravels testing syntax.

Take a look at the extension in action.

With just a few clicks, you just magically created a integration test for your registration process.

But wait! There’s more you can do!

If you, for example, want to generate dynamic data within your test, you can do this by using the Laravel TestTools context menu. The menu gives you access to some handy faker methods to generate emails, names or words on the fly.

Limitations

You can not test your Javascript/VueJS/AngularJS single page application with this. Even though the extension will generate the test code for you it will not work with Laravel. That’s because when Laravel is running these tests it doesn’t have Javascript. What happens, when Javascript runs your tests is that it simulates a GET/POST/whatever request to the specified URL and fetches and parses the resulting HTML DOM. That DOM is then used to modify input fields, search text and submit forms.

If you really need to test Javascript in a browser – take a look at “Selenium”. Jeffrey Way has you covered – https://laracasts.com/series/intuitive-integration-testing/episodes/5

This is awesome – can I help you?

You sure can – the source code is available on Github. This is the very first version of the Laravel TestTools extension, so there might be bugs, quirks or unexpected behavior. If you need any help, get in touch with me via Twitter or create an issue on the Github repository.

 

@refer:  http://marcelpociot.com/blog/2016-03-21-laravel-testtools

 

CSS Best architecture – CCSS [Component CSS]

Elements of CCSS

Below are the major elements used either fully or in a modified way to achieve the best configuration for the CCSS architecture.

SMACSS

SMACSS stands for Scalable and Modular Architecture for CSS. It is more of a style guide than a rigid framework. Read about SMACSS for background on the structure as CCSS uses it.

BEM

BEM stands for “Block”, “Element”, “Modifier”. It is a front-end methodology which is a new way of thinking when developing web interfaces. The guys at Yandex came up with BEM and more information can be found here.

SASS

SASS is CSS with superpowers. Highly recommend it but you can also use LESS if you prefer that. Please refer to the SASS documentation for more information.

try to follow : http://sass-guidelin.es/

Compass

Compass has no class definitions, it is an extension of SASS which provides a lot of utilities. It is used for general useful mixins, and sass compilation. Compass mixins should nearly always be used in cases where vendor prefixes are required. This again is a nice to have and Bourbon, on the first look is a great alternative.

 

Refer : https://github.com/sathify/CCSS

Refer this link for other standard practices : http://www.leemunroe.com/css/