protected override void beforeEach()
        {
            AssetDeclarationVerificationActivator.Latched = false;

            var logs = new AssetLogsCache();

            logs.FindByName(theAssetName)
            .Add(_provenance, "Test log message 1");
            logs.FindByName(theAssetName)
            .Add(_provenance, "Test log message 2");

            Services.Inject(logs);
        }
Esempio n. 2
0
        // For testing purposes only
        public static string GetErrorMessage(string name, AssetLogsCache logs)
        {
            var logsBuilder = new StringBuilder("Unable to locate asset named {0}".ToFormat(name));

            logsBuilder.AppendLine(Environment.NewLine + "Asset logs:");
            logs.FindByName(name).Logs.GroupBy(l => l.Provenance)
            .Each((grouped) =>
            {
                logsBuilder.AppendLine("    {0}".ToFormat(grouped.Key));
                foreach (var assetLogEntry in grouped)
                {
                    logsBuilder.AppendLine("        {0}".ToFormat(assetLogEntry.Message));
                }
            });

            return(logsBuilder.ToString());
        }
Esempio n. 3
0
 public AssetDeclarationChecker(IAssetPipeline pipeline, IPackageLog log, AssetLogsCache assetLogs)
 {
     _pipeline  = pipeline;
     _log       = log;
     _assetLogs = assetLogs;
 }
Esempio n. 4
0
 public AssetGraphConfigurationActivator(AssetGraph assets, IFileSystem fileSystem, AssetLogsCache logs)
 {
     _assets      = assets;
     _fileSystem  = fileSystem;
     _diagnostics = new AssetRegistrationDiagnostics(_assets, logs);
 }
 public RecordingAssetFileRegistrator(IAssetFileRegistration inner, AssetLogsCache assetLogsCache)
 {
     _inner          = inner;
     _assetLogsCache = assetLogsCache;
 }
 public AssetPipelineBuilderActivator(IAssetFileRegistration pipeline, AssetLogsCache assetLogsCache)
 {
     _pipeline = new RecordingAssetFileRegistrator(pipeline, assetLogsCache);
 }
Esempio n. 7
0
 public AssetsEndpoint(AssetGraph graph, AssetLogsCache assetLogs)
 {
     _graph     = graph;
     _assetLogs = assetLogs;
 }
Esempio n. 8
0
 public AssetDeclarationChecker(IAssetFileGraph fileGraph, IPackageLog log, AssetLogsCache assetLogs)
 {
     _fileGraph = fileGraph;
     _log       = log;
     _assetLogs = assetLogs;
 }
 public AssetDeclarationVerificationActivator(IAssetFileGraph fileGraph, AssetGraph graph, AssetLogsCache assetLogs)
 {
     _fileGraph = fileGraph;
     _graph     = graph;
     _assetLogs = assetLogs;
 }
Esempio n. 10
0
 public AssetDeclarationVerificationActivator(IAssetPipeline pipeline, AssetGraph graph, AssetLogsCache assetLogs)
 {
     _pipeline  = pipeline;
     _graph     = graph;
     _assetLogs = assetLogs;
 }