TISTUD-4739 Fix failed unit tests on studio3 repo

  - fix unit test that fails if default charset is not UTF-8 by setting default charset for CSS files to be UTF-8 according to content type declaration.
  - fix failing JS formatter tests
  - fix unit test for reading/writing UTF-8. Previously the test assumed the default charset was UTF-8, which it is not on the build machine.
  - fix failing unit test for adding git remotes. Need to add overloaded method to be able to specify if we auto-fetch or not, since unit test uses fake remote URI
  - fix failing test due to NPE
  - fix failing unit tests (because "const" is longer special keyword in JS)
  - Modify test that runs extremely slowly on build machine testing chmod/get permissions. Spot check 10 random permissions values rather than the entire range every time. Only create one file and use that for each permission, rather than a new one each time.