A Fitting Conclusion

The final week of my internship was a gratifying one. Not that the other weeks weren’t gratifying (au contraire!), but as luck would have it, one of the final bugs I grappled with turned out to require pretty much everything I’ve learned about exploratory testing during my time with Wikimedia Foundation.

The bug had to do with translating musical scores.

A little background:  MediaWiki has an extension that converts Lilypond or ABC musical notation into an engraved score, with an option to produce an audio file as well. In the wikitext version of a page, these elements are surrounded by <score> tags, so we usually refer to them as “score elements.”

A week or so before the end of the internship, one of my mentors asked me to look into a bug in which a page containing several score elements was not translating correctly. Normally, you can translate a page paragraph by paragraph – but the page containing the score elements would only translate as one monolithic block.

I began by finding and testing other pages that contained score elements. I wanted to get complete coverage of all the variables, so I tried all these permutations (as listed in my initial testing report):

  • Tested on these language pairs: English>Hebrew, English>Chinese, English>Guarani, English>Spanish, English>Tajik, French>Russian
  • Tested both Lilypond and ABC input.
  • Tested both block and inline <score> elements.
  • Tested all translation engines available for each language pair.

Interestingly, I encountered almost no problems translating score elements! There was a single translation engine (of 5) that was unable to translate a score element from English to Chinese, but overall support was very robust. Not once did I encounter the issue described in the bug report – a page that would only translate as a single block.

That made me wonder if something other than <score> elements could be to blame.

There were other pages by the same author and in the same category (Tone Poems of Richard Strauss) as the reported page. I tried translating these pages and discovered that every last one of them had the same problem. Clearly they had something in common that was tripping up the parser. If it wasn’t the score elements, what was it?

I examined the wikitext of each of the pages, looking for common features. I found that each of the pages began with a particular template whose purpose was to italicize the page title, followed by a thumbnail image.

Wikipedia tracks which pages — among all the tens of thousands that are posted there — use a particular template, so I began testing pages that, like the Strauss Tone Poem pages, began with the Italic title template. I encountered no problems in translating those pages. Next I tracked down and began testing the subset of pages that began with an Italic title template immediately followed by a thumbnail image.

Voila! Every last example that I found translated as a monolithic block rather than translating paragraph by paragraph! And as further evidence that score elements were not to blame, most of those pages did not include even a single score element.

I can’t tell you why that particular combination of elements – Italic Title plus thumbnail image – causes a problem for the parser, but I can tell you that it DOES, and that brings us a step closer to a solution. (Remember, my single arrow does not have to bring down the entire buffalo; see my last blog post: Teamwork.)

It was a fantastic puzzle to test my newfound testing skills, and a very gratifying way to end the internship!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s