예제 #1
0
        public JasmineConfiguration Configure(string file, ISerenityJasmineApplication application)
        {
            file = file.ToFullPath();

            JasmineConfiguration config;

            if (_fileSystem.IsFile(file))
            {
                Console.WriteLine("Reading directives from " + file);
                if (!_fileSystem.FileExists(file))
                {
                    throw new CommandFailureException(
                              "Designated serenity/jasmine file at {0} does not exist".ToFormat(file));
                }

                config = _configLoader.LoadFrom(file);
            }
            else
            {
                config = new JasmineConfiguration(file);
                config.AddContentFolder(file);
            }

            ProcessConfiguration(config, application);

            return(config);
        }
예제 #2
0
        public JasmineConfiguration Configure(string file, ISerenityJasmineApplication application)
        {
            file = file.ToFullPath();

            JasmineConfiguration config;
            if (_fileSystem.IsFile(file))
            {
                Console.WriteLine("Reading directives from " + file);
                if (!_fileSystem.FileExists(file))
                {
                    throw new CommandFailureException(
                        "Designated serenity/jasmine file at {0} does not exist".ToFormat(file));
                }

                config = _configLoader.LoadFrom(file);
            }
            else
            {
                config = new JasmineConfiguration(file);
                config.AddContentFolder(file);
            }

            ProcessConfiguration(config, application);

            return config;
        }
예제 #3
0
        private static void include(string text, JasmineConfiguration config)
        {
            var folder = text.Split(':').Last();

            config.AddContentFolder(folder);
        }
예제 #4
0
 private static void include(string text, JasmineConfiguration config)
 {
     var folder = text.Split(':').Last();
     config.AddContentFolder(folder);
 }