the startup agency - a case study on cfpb

33
CFPB: The federal government’s newest startup Greg Boone, Dave Kennedy, Dan Munz WordPress in Government JUNE 13, 2013

Upload: govloop

Post on 05-Dec-2014

13.032 views

Category:

Technology


3 download

DESCRIPTION

Hear Dan Munz, David Kennedy and Greg Boone discuss how CFPB was born, what challenges they faced and how WordPress became their CMS backbone throughout it all.

TRANSCRIPT

Page 1: The StartUp Agency - A Case Study on CFPB

CFPB: The federal government’s newest startupGreg Boone, Dave Kennedy, Dan Munz

WordPress in Government

JUNE 13, 2013

Page 2: The StartUp Agency - A Case Study on CFPB

Today’s agenda

A little background

WordPress at CFPB

Behavior-driven WordPress development

View-source, the WordPress way!

2

Page 3: The StartUp Agency - A Case Study on CFPB

A little background

Page 4: The StartUp Agency - A Case Study on CFPB

4

“It is impossible to buy a toaster that has a one-in-five chance of bursting into flames and burning down your house. But it is possible to refinance an existing home with a mortgage that has the same one-in-five chance of putting the family out on the street–and the mortgage won’t even carry a disclosure of that fact to the homeowner.”

Unsafe at Any RateSummer 2007

Page 5: The StartUp Agency - A Case Study on CFPB

JULY 2010

Page 6: The StartUp Agency - A Case Study on CFPB

JULY 2011

Page 7: The StartUp Agency - A Case Study on CFPB

JULY 2012

Page 8: The StartUp Agency - A Case Study on CFPB
Page 9: The StartUp Agency - A Case Study on CFPB

consumerfinance.gov

Launched in February 2011 (5 months ahead of

schedule)

The Bureau’s (only!) owned digital property

Consumers are our core audience

About 900K unique pageviews/month

9

Page 10: The StartUp Agency - A Case Study on CFPB

WP @ CFPB

Page 11: The StartUp Agency - A Case Study on CFPB

Our stack

11

Page 12: The StartUp Agency - A Case Study on CFPB

Standard content types

Good CM interface Distributed editorial

workflow

Custom app development

Highly interactive or database-driven

Infrequent content updates

CMS vs. Framework?

12

Page 13: The StartUp Agency - A Case Study on CFPB

More peopledoing

fewer things

Fewer people doing

more things

In other words

13

Page 14: The StartUp Agency - A Case Study on CFPB

What we’ve learned

WP is not (natively) a web application

framework

Some core capabilities are still maturing

Easy to do things right; even easier to do things

wrong

Understand how Security thinks about OSS

14

Page 15: The StartUp Agency - A Case Study on CFPB

Big hairy questions

Consistently structuring complex taxonomies

and data relationships

Pushing reusable code blocks into modules or

plugins

Making templating platform-agnostic

15

Page 16: The StartUp Agency - A Case Study on CFPB

That’s how we’re thinking about WordPress…

…but how are we using it?

16

Page 17: The StartUp Agency - A Case Study on CFPB

17OMG DAN SHUT UP

Page 18: The StartUp Agency - A Case Study on CFPB

Behavior-driven

WordPress

developmentor: “How a little Python can go a long way for PHP”

Page 19: The StartUp Agency - A Case Study on CFPB

The plugin

We needed an easier way to register:

Post types with default settings

Taxonomies with custom entry boxes

Meta boxes

Capabilities

We were doing it all in the theme; we transitioned

to a plugin with a UI.

19

Page 20: The StartUp Agency - A Case Study on CFPB

How to know it’ll work

Two choices:

1. Manual entry of each post type, then manual

entry of one term for each taxonomy

2. Automated behavior testing!

20

Page 21: The StartUp Agency - A Case Study on CFPB

Enter behave

Simple, scenario based tests…

Scenario: Get more

information about us

Given I visit the

homepage

When I click the "About

us" link

Then I should be

directed to /about/

Optionally, add an and

condition after a when or then

21

…organized into simple features!

Feature: Transparency in

the Bureau

As a member of the public

I want to learn more

about this organization

So that I can understand

their work better

And a real browser

(Chrome) to perform them!

Page 22: The StartUp Agency - A Case Study on CFPB

[DEMO]

22

Page 23: The StartUp Agency - A Case Study on CFPB

Okay, so you can teach a computer to log in…

23

What about a real test?

1. Log in

2. Go to the Custom Post Type page

3. Create three post types

4. Deactivate all three

5. Re-activate all three

Total execution time: 33 seconds (with about half of that going to wp-login)

Page 24: The StartUp Agency - A Case Study on CFPB

Benefits of testing

24

1. You know your plugin works

2. You can spot bugs on the fly

3. Programming toward specific behaviors

4. It's way faster than doing it all by hand

5. Eventually, you write better code.

6. You always know if the feature works or not

Page 25: The StartUp Agency - A Case Study on CFPB

Still learning…

25

It'd be nice to not have to log in _every_ time

Writing the steps can be tricky (but it's python, so not too tricky)

Page 26: The StartUp Agency - A Case Study on CFPB

view-source

the WordPress way!

Page 27: The StartUp Agency - A Case Study on CFPB

We all start somewhere

27

Page 28: The StartUp Agency - A Case Study on CFPB

But as we go, we learn

28

Page 29: The StartUp Agency - A Case Study on CFPB

Building, building, building…

29

Page 30: The StartUp Agency - A Case Study on CFPB

Embrace the WordPress community

They’re the source for solving your problems and giving you inspiration to solve theirs…

Automattic’s Github WordPress.org Forums Themeshaper.com WordPress.org Plugin Directory Also, blogs!

30

Page 31: The StartUp Agency - A Case Study on CFPB

How is the CFPB “viewing source”?

Hello Underscores! Forked; becoming our new base!

WordPress goodness baked in. Miminimalistic; easily extendable. Solid framework and conventions

31

Page 32: The StartUp Agency - A Case Study on CFPB

How is the CFPB “viewing source”?

Talking it out with P2 A trial run for managing our internal workgroups.

Turns out blogs are great for conversations!

A child theme allows us to brand it and extend it.

32

Page 33: The StartUp Agency - A Case Study on CFPB

How is the CFPB “viewing source”?

Going more modular Embracing <?php get_template_part() ?>

We were already doing this, but where can we do it more?

Find a best practice and ask how are we doing that?

33