This lead to any supporting page which used `InlineAttachment` in its code to have the final attachment inserted instead of the intended one when generating the policy papers. This migration is unlikely to be run again but the code may be reused, possibly to regenerate the policy papers, hence the fix. The 42 supporting pages affected were: ``` 271711 272265 273639 295176 300636 304881 318193 335116 338542 345583 360752 374073 376562 396483 396846 405190 405387 436196 438390 446469 447757 457906 459673 459753 459823 461549 462074 462717 463689 466218 469982 474181 478983 479711 480879 481023 482618 483143 483331 486735 486884 490567 ```
Since the renaming of policies to make them more generic we have been seeing people get confused between policies and topics. This removes topics from the metadata on documents so that people won't get confused. This also follows the pattern which is to eventually get rid of topics.
Currently courts/tribunals have their "What we do" heading replaced with "Who we are". This reverts that, making it consistent with normal organisations.
Script was relying on the previous behaviour of automatically searching friendly IDs with `find`. Update to use the more explicit `find_by`.
As the comments at the top of the file states, this file is generated by cucumber-rails and shouldn't really be edited, otherwise it is not safe to regenerate the file for newer versions of cucumber-rails. Therefor it is better to keep cucumber-related setup, helpers and filters elsewhere.
A world location was being created for every single feature, when it is only really needed for those that involve editing contacts. This makes the creation of the dependent location explicit in those features that require it. This was causing an exception to be raised because of cucumber is evaluating features/support/env.rb before features/support/publishing_api.rb, which means the calls to Publishing API have not been stubbed in time for the create(:world_location) call. This was previously working because ActiveRecord suppressed errors raised in after_commit callbacks prior to version 4.2.
Prior to Rails 4.2, ActiveRecord would suppress errors raised in after_rollback or after_commit callbacks and only print them to the logs. Rails 4.2 no longer does this. Instead of replicating the old behaviour, which will mask bugs, we opt-in to the new behaviour and fix the bugs that were previously being masked. See http://guides.rubyonrails.org/upgrading_ruby_on_rails.html#error-handling-in-transaction-callbacks
New style policies don't have short descriptions like the old ones used to have. This means the pages don't look great with the descriptions visible. Also we have now switched to showing more policies in these lists so a shorter list is preferable. Remove a `overflow:hidden` as it was previously used to contain floats. The only element with the element which has any floated elements also has our float clear fix so it was redundant and caused the top of some of the text to be chopped off.