[#445] Only lookup strings in term translation table

This fixes the multilingual tests that are currently failing on master.

It seems that when the multilingual extension was written, package dicts
never contained ints as values. Now they do. But postgres cannot compare
an int to a string so it crashes. This commit changes the multilingual
plugin so that it only tries to lookup strings in the term translation
table, other types are just skipped.

Fixes #445.
Replace deprecated has_key with in
Fix spelling
Fix docstring for resource_search
Remove unused variables and ; at end of line
[#445] Refactor a loop in multilingual plugin

This just makes a small loop in ckanext/multilingual clearer, the logic
should be the same.
Merge pull request #467 from domoritz/minor-fixes

Minor fixes
Merge pull request #457 from okfn/445-bug-multilingual-tests-failing-2

[#445] Only lookup strings in term translation table
[#446] Accept either .min.js or .js in ckanext/*preview tests

We don't care if the page which one is added to the page, as long as
one of them is there.

Fixes #446.
[#462] Don't print the whole HTML whenever we get a failure

As per suggestion by @seanh in https://github.com/okfn/ckan/pull/462#issuecomment-14039804