Friday, May 1, 2015

Automated Testing of Drupal 8 Modules

In this article we are going to look at automated testing in Drupal 8. More specifically, we are going to write a few integration tests for some of the business logic we wrote in the previous Sitepoint articles on Drupal 8 module development. You can find the latest version of that code in this repository along with the tests we write today.

Drupal 8 logo

But before doing that, we will talk a bit about what kinds of tests we can write in Drupal 8 and how they actually work.

Simpletest (Testing)

Simpletest is the Drupal specific testing framework. For Drupal 6 it was a contributed module but since Drupal 7 it has been part of the core package. Simpletest is now an integral part of Drupal core development, allowing for safe API modifications due to an extensive codebase test coverage.

Right off the bat I will mention the authoritative documentation page for Drupal testing with Simpletest. There you can find a hub of information related to how Simpletest works, how you can write tests for it, what API methods you can use, etc.

By default, the Simpletest module that comes with Drupal core is not enabled so we will have to do that ourselves if we want to run tests. It can be found on the Extend page named as Testing.

Once that is done, we can head to admin/config/development/testing and see all the tests currently available for the site. These include both core and contrib module tests. At the very bottom, there is also the Clean environment button that we can use if any of our tests quit unexpectedly and there are some remaining test tables in your database.

Continue reading %Automated Testing of Drupal 8 Modules%


by Daniel Sipos via SitePoint

Vote Yes Yes Yall!

Vote Yes Yes Yall!

Colorful One Pager encouraging users to vote "Yes" at the Marriage Equality Referendum happening in Ireland this month. The site provides a neat tool where you can change your Facebook profile image to a "yes face" in the matter of a few clicks. Simple but fun One Pager that's straight to the point and for a good cause. Good luck!

by Rob Hope via One Page Love

Creating a Brand Identity: 20 Questions You MUST ask BEFORE You Start

“No. This just doesn’t look right”.

What do you do when a client says that? Especially if it’s about the design you just sent in after a whole week of loving labour.

For a designer, the worst clients are the ones who don't know what they want. These are the ones who don't give clear instructions, ask for multiple revisions and insist they’ll "know it's right when they see it".

As designers, we’re responsible for delivering not just the visuals as a pdf, psd, or .svg but also for delivering the intangible associations with those visuals.

It can get icky when working with clients who lack clarity. It is part of our job, to help clients achieve that clarity.

Part of our job is to help clients achieve clarity about their brand identity.

You don’t want to be caught in multiple cycles of design iterations, hoping the client likes your work. Or experimenting with different shades of blue.

To avoid the heartburn later - front load the work. Ask prospective clients direct and detailed questions before finalizing the project. This will give you a glimpse into how clear they are about their business, their prospects and their brand identity. Using this you can judge how much hand holding will be required and make that crucial decision: are you willing to put in the time and effort?

Along with mapping out a clear brand identity, you can frame the questions to leverage a few indirect benefits like:

  • Inspire confidence and trust in the client: You’re a thorough professional and are making a genuine effort to understand their business and needs. If the business owner has not yet given much thought to these questions, they’ll appreciate the guidance and clarity it brings. This also softens them up a bit to be open to the rates you quote in your proposal.
  • Save time and effort: You can weed out clients are not worth your time to consider writing out a proposal for. And for clients that do come on board, it helps avoid unnecessary revisions and disputes during the project.
  • Deliver better, grow more: You can tune in better to your clients and craft a brand identity that best matches the client needs. Happy clients are more likely to give you glowing testimonials and more referral work.

To make it easier for you, we’ve summarized the most essential questions designers should ask potential clients, before embarking on the actual design, or even before signing up for the project at all.

About the Business

Design is a very subjective process. You will need to work closely with your client, to understand their business and the direction they want to take it.

1. What does your business / product do? Remember this is not their corporate 'About' page. Instead, this should be on the lines of their elevator pitch. If they had just 30 seconds to explain their product to a customer, what would they say?

2. What problem do you solve for your customers? What is the purpose of their existence (other than to make money)? If a business is not solving a problem or fulfilling a need for customers, then it’s not worth while.

3. Who are your 3 main competitors (direct or indirect)? What do you like about their presence? What do you dislike about their brand identity? It pays to know who you’re competing against and what the industry norms are. Know them, learn from them, but don’t ape them. Do your own thing.

4. What about your background or product or service sets you apart from your competitors? Why should your prospects buy from you or engage with you? Consumers today are spoilt for choice. If your clients can't describe in a sentence or two what their USP is, steer them over to this explanation over at Kissmetrics and help them define theirs.

5. Is there a unique story behind your business or business name or logo? People connect through stories. Storytelling is an effective way to create and sell a brand image. Find out what are the stories behind the business, the products, and the customers. The story creates the customer. Here's how to tell a great brand story.

6. Share 5 adjective or words that best describe your company. I love the simplicity of this. The words they choose convey a lot of meaning regarding how they see themselves, or how they want to see themselves.

The Best brands are built on great stories

About the Project

The next part relates to the project at hand. Get into the details of what they really need, and why. This helps set clear expectations from the beginning and avoids scope creep or heated exchanges later.

7. What are the Deliverables for the brand identity? It’s better to clearly document what your deliverables will be. Brand identity is vast and can include stationery, logo, website, product packaging, marketing collateral and others.

8. Does any of your current material need to be updated to match the new brand identity? These are often overlooked during the initial phases. To avoid last minute scope creep, make sure to ask the client to clearly spell out any and all existing material that will have to be updated.

9. Who are the decision makers on this project? What is the turnaround time for making a decision? After an exhaustive questionnaire and detailed proposal you don’t want to find you were talking to the assistant to the assistant of the guy who has to make the decision, and will have to repeat the whole process all over again!

10. What timelines are you’re looking at for this project? What is your budget? Given your other commitments and the scope of this project, will you be able to deliver the project within the required time frame? If their budget is way too low, or the timeline too short, you can politely decline upfront and not spend the time and effort to create a proposal.

About Their Customers

Who do you design for? Client or customer?

Who should you really design for? Your client or their customer?

While your client is the one who has to approve your design and pay for it, their revenues in turn come from their customers. Designers often end up trying to impress and please their clients - tuning the design to suit their color preferences, tastes etc. However, the client is not the one the design has to influence and sway. Your design must woo the end customer.

11. Describe your ideal customer? Selling to another business is different from selling to a consumer. The brand identity should take that into account.If they already have an Ideal Customer Profile, you can ask them to share that. If not, ask for demographic details along with a psychological profile or story. Here’s an exercise from Bidsketch that you can guide them through to create their ICP.

12. What is the primary message do want to convey to your customers? This does not have to be just a verbal message. This is about how they want customers to feel each time they interact with the business. How do people feel each time you mention an iPhone?

13. Share 5 adjective or words that best describe your ideal customer. Do they know their customers well enough to be able to describe them in a few short words? If not, you're going to have to do some hand holding to help them know their customers better.

14. Do you have any market research about your ideal client or your product/business that you can share with us? Market research is often sensitive. Offering to sign a non-disclosure agreement before they share any such information will help convey that you're serious about this and can be trusted.

About the Identity

Make it simple, but significant. Don Draper.

The questions above form the basis of the section. Only once you’ve understood your clients and their customers, does it make sense to even start talking about the brand identity.

15. What is the purpose behind this exercise? Why now? No one wakes up and says ‘Oh, I have to create a new brand identity for the business today’. It comes after considerable thought and effort. Ask what your client wants to achieve from this exercise, and what their end goals are.

Continue reading %Creating a Brand Identity: 20 Questions You MUST ask BEFORE You Start%


by Richa Jain via SitePoint

An Introduction to Android Accessibility Features

Everybody agrees that an app should be easy to use, intuitive and user friendly, but is that enough? We often forget that an important part of app development is making sure your app is accessible and easy to navigate for everyone, even those with visual or physical disabilities.

Android offers a lot of accessibility options and features but they are often neglected during the design and implementation phase. Accessibility APIs were first introduced in Android 1.6 (API level 4) but many developers are not familiar or interested in them. Accessibility has often been an after-thought and if you make a quick search on Google or StackOverflow, there are few mentions.

It shouldn’t be this way, because implementing accessibility features into your app is easy and straightforward, so today we are going to take a look at how.

Continue reading %An Introduction to Android Accessibility Features%


by Donald Dragoti via SitePoint

DocT Zahnarzt

DocT Zahnarzt

Responsive One Pager featuring a Masonry arrangement of colorful imagery for a Berlin-based dentist called 'Doct Zahnarzt'. Not really feeling the scroll within the information modal but what a refreshing design for a dentist. Cheers for letting us know the brief below, sounds like a great client.

by Rob Hope via One Page Love

Moving WordPress: Moving a Multisite Network

Alexander Dodge Design

Alexander Dodge Design

AJAX loading responsive One Pager for award-winning set & costume designer, 'Alexander Dodge'. The work is presented in AJAX loading modals featuring brilliant imagery of his glamorous work. Great to see another One Page portfolio in a different industry. Also worth noting the site is built on WordPress.

by Rob Hope via One Page Love