[roll] Fix version file generation and improve tests

Only the last line of the VERSION file was actually written and this
wasn't covered by tests. Now the tests also check that the correct
VERSION file is written.


Change-Id: Ib4cfa7548ed123e309428276eaaface2391df47c
Reviewed-on: https://dart-review.googlesource.com/c/recipes/+/158041
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
2 files changed