Upgrade Your Drupal Skills

We trained 1,000+ Drupal Developers over the last decade.

See Advanced Courses NAH, I know Enough
Mar 12 2020
Mar 12

Category 1: Web development

Category 2: Drupal

Category 3: Data architecture and engineering

Category 4: Data analytics

Category 5: Design, research, and content strategy

Category 6: Operations

Feb 06 2019
Feb 06

Mass.gov dev team releases open source project

Moshe Weitzman

The Mass.gov development team is proud to release a new open source project, Drupal Test Traits (DTT). DTT enables you to run PHPUnit tests against your Drupal web site, without wiping your database after each test class. That is, you test with your usual content-filled database, not an empty one. We hope lots of Drupal sites will use DTT and contribute back their improvements. Thanks to PreviousNext and Phase2 for being early adopters.

Mass.gov is a large, content-centric site. Most of our tests click around and assert that content is laid out properly, the corresponding icons are showing, etc. In order to best verify this, we need the Mass.gov database; testing on an empty site won’t suffice. The traditional tool for testing a site using an existing database is Behat. So we used Behat for over a year and found it getting more and more awkward. Behat is great for facilitating conversations between business managers and developers. Those are useful conversations, but many organizations are like ours — we don’t write product specs in Gherkin. In fact, we don’t do anything in Gherkin beside Behat.

Meanwhile, the test framework inside Drupal core improved a lot in the last couple of years (mea culpa). Before Drupal Test Traits, this framework was impossible to use without wiping the site’s database after each test. DTT lets you keep your database and still test using the features of Drupal’s BrowserTestBase and friends. See DrupalTrait::setUp() for details (the bootstrap is inspired by Drush, a different open source project that I maintain).

Zakim Bridge at Night, North End Boston. Photo by David Fox.
  • Our test cases extend ExistingSiteBase, a convenience class from DTT that imports all the test traits. We will eventually create our own base class and import the traits there.
  • Notice calls to $this->createNode(). This convenience method wraps Drupal’s method of the same name. DTT deletes each created node during tearDown().
  • Note how we call Vocabulary::load(). This is an important point — the full Drupal and Mink APIs are available during a test. The abstraction of Behat is happily removed. Writing test classes more resembles writing module code.
  • See the DTT repo for details on how to install and run tests
  • Typically, one does not run tests against a live web site. Tests can fail and leave sites in a “dirty” state so it’s helpful to occasionally refresh to a pristine database.

If you have questions or comments about DTT, please comment below or submit issues/PRs in our repository.

More from Moshe: Our modern development environment at Mass.gov

Interested in a career in civic tech? Find job openings at Digital Services.
Follow us on Twitter | Collaborate with us on GitHub | Visit our site

Oct 19 2018
Oct 19
Deirdre Habershaw

Today, more than 80% of people’s interactions with government take place online. Whether it’s starting a business or filing for unemployment, too many of these experiences are slow, confusing, or frustrating. That’s why the Commonwealth created Massachusetts Digital Service (Mass Digital) in the Executive Office of Technology and Security Services. Mass Digital is at the forefront of the state’s digital transformation. Its mission is to leverage the best technology and information available to make people’s interactions with state government fast, easy, and wicked awesome. There’s a lot of work to do, but we’re making quick progress.

Mass Digital worked with the new Department of Family and Medical Leave (DFML) to launch the Commonwealth’s first digitally native service: Paid Family and Medical Leave and PaidLeave.mass.gov. We’ve been on the front lines of the pandemic response, supporting the Department of Unemployment Assistance to create capabilities for multilingual unemployment claims (Unemployment.mass.gov) and doing content design to keep up with rapidly evolving pandemic unemployment benefits, and supporting the Department of Public Health and Command Center to launch the state’s vaccine preregistration system (VaccineSignUp.mass.gov).

If you want to work in a fast-paced agile environment, with a good work life balance, solving hard problems, working with cutting-edge technology, and making a difference in people’s lives, you should join Massachusetts Digital Service.

We are currently recruiting designers, researchers, and product managers. Here are links to open job postings:

If you are interested in working with us, please submit your resume here.

Check out more about hiring at the Executive Office of Technology and Security Services and submit your resume in order to be informed on roles as they become available.

Feb 11 2016
Feb 11

amazon-web-services-drupal-architectureamazon-web-services-drupal-architecture

Mobomo believes in partnering. Over the years we have partnered with Amazon, IBM, Tracx, and a number of other companies and organizations. We are pleased to announce our recent partnership with the Drupal Association (https://assoc.drupal.org), Drupal has been a major contributor in the community for many years. 

Drupal is an open-source content management system framework used to make many of the websites and applications that you use every day. Drupal has great standard features like easy content authoring, reliable performance, and excellent security. But what sets Drupal apart from other solutions is its flexibility and extensibility; modularity is one of its core principles. Drupal allows you to build the versatile, structured content that is needed for engaging and dynamic web experiences.

We are very pleased to be a part of the Drupal community, since we have developed Drupal solutions for major Federal Government websites in the past this partnership only makes sense. We are excited about our partnerships and look forward to building bigger and better things as a supporting partner of Drupal.org. Be sure to visit our Drupal page.

About Drupal Sun

Drupal Sun is an Evolving Web project. It allows you to:

  • Do full-text search on all the articles in Drupal Planet (thanks to Apache Solr)
  • Facet based on tags, author, or feed
  • Flip through articles quickly (with j/k or arrow keys) to find what you're interested in
  • View the entire article text inline, or in the context of the site where it was created

See the blog post at Evolving Web

Evolving Web