Describe("#SyncLTC", func() {
		It("should download ltc from the target and swap it with ltc", func() {
			fakeServer.RouteToHandler("GET", "/v1/sync/amiga/ltc", ghttp.CombineHandlers(
				ghttp.RespondWith(200, []byte{0x01, 0x02, 0x03}, http.Header{
					"Content-Type":   []string{"application/octet-stream"},
					"Content-Length": []string{"3"},
				}),
			))

			tmpFile, err := ioutil.TempFile("", "")
			Expect(err).NotTo(HaveOccurred())
			defer os.Remove(tmpFile.Name())

			fakeFileSwapper.GetTempFileReturns(tmpFile, nil)

			versionManager.SyncLTC(ltcTempFile.Name(), "amiga", config)

			Expect(fakeServer.ReceivedRequests()).To(HaveLen(1))

			Expect(fakeFileSwapper.GetTempFileCallCount()).To(Equal(1))

			Expect(fakeFileSwapper.SwapTempFileCallCount()).To(Equal(1))
			actualDest, actualSrc := fakeFileSwapper.SwapTempFileArgsForCall(0)
			Expect(actualDest).To(Equal(ltcTempFile.Name()))
			Expect(actualSrc).To(Equal(tmpFile.Name()))

			tmpFile, err = os.OpenFile(tmpFile.Name(), os.O_RDONLY, 0)
			Expect(err).NotTo(HaveOccurred())

			bytes, err := ioutil.ReadAll(tmpFile)
			Expect(err).NotTo(HaveOccurred())