public async Task Prep(CancellationToken cancel) { await Task.WhenAll( Task.Run(async() => { _logger.Information("Compiling"); try { var resp = await Build.Compile(PathToProjProvider.Path, cancel).ConfigureAwait(false); if (!resp.Succeeded) { throw new SynthesisBuildFailure(resp.Reason); } _logger.Information("Compiled"); } catch (Exception e) { _logger.Error(e, "Failed to compile"); throw; } }), Task.Run(() => { CopyOverExtraData.Copy(); })).ConfigureAwait(false); }
public void DeepCopyNotCalledIfDefaultDataMissing( DirectoryPath missingDir, DirectoryPath existingDir, CopyOverExtraData sut) { sut.DefaultDataPathProvider.Path.ReturnsForAnyArgs(missingDir); sut.UserExtraData.Path.ReturnsForAnyArgs(existingDir); sut.Copy(); sut.DeepCopy.DidNotReceiveWithAnyArgs().DeepCopy(default, default);