Got lots of the default values configured with unit tests, still need to finish the rest though.

This commit is contained in:
Shannon
2013-09-02 16:36:47 +10:00
parent 7806762b80
commit 5cd04b5c9e
14 changed files with 500 additions and 39 deletions

View File

@@ -43,7 +43,13 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
[ConfigurationProperty("UploadAllowDirectories")]
internal InnerTextConfigurationElement<bool> UploadAllowDirectories
{
get { return (InnerTextConfigurationElement<bool>)this["UploadAllowDirectories"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["UploadAllowDirectories"],
//set the default
true);
}
}
[ConfigurationProperty("errors")]
@@ -61,13 +67,25 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
[ConfigurationProperty("ensureUniqueNaming")]
public InnerTextConfigurationElement<bool> EnsureUniqueNaming
{
get { return (InnerTextConfigurationElement<bool>)base["ensureUniqueNaming"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["ensureUniqueNaming"],
//set the default
true);
}
}
[ConfigurationProperty("TidyEditorContent")]
public InnerTextConfigurationElement<bool> TidyEditorContent
{
get { return (InnerTextConfigurationElement<bool>)base["TidyEditorContent"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["TidyEditorContent"],
//set the default
false);
}
}
[ConfigurationProperty("TidyCharEncoding")]
@@ -78,80 +96,155 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["TidyCharEncoding"],
//set the default
"Raw");
"UTF8");
}
}
[ConfigurationProperty("XmlCacheEnabled")]
public InnerTextConfigurationElement<bool> XmlCacheEnabled
{
get { return (InnerTextConfigurationElement<bool>)base["XmlCacheEnabled"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["XmlCacheEnabled"],
//set the default
true);
}
}
[ConfigurationProperty("ContinouslyUpdateXmlDiskCache")]
public InnerTextConfigurationElement<bool> ContinouslyUpdateXmlDiskCache
{
get { return (InnerTextConfigurationElement<bool>)base["ContinouslyUpdateXmlDiskCache"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["ContinouslyUpdateXmlDiskCache"],
//set the default
true);
}
}
[ConfigurationProperty("XmlContentCheckForDiskChanges")]
public InnerTextConfigurationElement<bool> XmlContentCheckForDiskChanges
{
get { return (InnerTextConfigurationElement<bool>)base["XmlContentCheckForDiskChanges"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["XmlContentCheckForDiskChanges"],
//set the default
false);
}
}
[ConfigurationProperty("EnableSplashWhileLoading")]
public InnerTextConfigurationElement<bool> EnableSplashWhileLoading
{
get { return (InnerTextConfigurationElement<bool>)base["EnableSplashWhileLoading"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["EnableSplashWhileLoading"],
//set the default
false);
}
}
[ConfigurationProperty("PropertyContextHelpOption")]
public InnerTextConfigurationElement<string> PropertyContextHelpOption
{
get { return (InnerTextConfigurationElement<string>)base["PropertyContextHelpOption"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["PropertyContextHelpOption"],
//set the default
"text");
}
}
[ConfigurationProperty("UseLegacyXmlSchema")]
public InnerTextConfigurationElement<bool> UseLegacyXmlSchema
{
get { return (InnerTextConfigurationElement<bool>)base["UseLegacyXmlSchema"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["UseLegacyXmlSchema"],
//set the default
false);
}
}
[ConfigurationProperty("ForceSafeAliases")]
public InnerTextConfigurationElement<bool> ForceSafeAliases
{
get { return (InnerTextConfigurationElement<bool>)base["ForceSafeAliases"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>)this["ForceSafeAliases"],
//set the default
true);
}
}
[ConfigurationProperty("PreviewBadge")]
public InnerTextConfigurationElement<string> PreviewBadge
{
get { return (InnerTextConfigurationElement<string>)base["PreviewBadge"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["PreviewBadge"],
//set the default
@"<a id=""umbracoPreviewBadge"" style=""position: absolute; top: 0; right: 0; border: 0; width: 149px; height: 149px; background: url('{1}/preview/previewModeBadge.png') no-repeat;"" href=""{0}/endPreview.aspx?redir={2}""><span style=""display:none;"">In Preview Mode - click to end</span></a>");
}
}
[ConfigurationProperty("UmbracoLibraryCacheDuration")]
public InnerTextConfigurationElement<int> UmbracoLibraryCacheDuration
{
get { return (InnerTextConfigurationElement<int>)base["UmbracoLibraryCacheDuration"]; }
get
{
return new OptionalInnerTextConfigurationElement<int>(
(InnerTextConfigurationElement<int>)this["UmbracoLibraryCacheDuration"],
//set the default
1800);
}
}
[ConfigurationProperty("MacroErrors")]
public InnerTextConfigurationElement<string> MacroErrors
public InnerTextConfigurationElement<MacroErrorBehaviour> MacroErrors
{
get { return (InnerTextConfigurationElement<string>)base["MacroErrors"]; }
get
{
return new OptionalInnerTextConfigurationElement<MacroErrorBehaviour>(
(InnerTextConfigurationElement<MacroErrorBehaviour>)this["MacroErrors"],
//set the default
MacroErrorBehaviour.Inline);
}
}
[ConfigurationProperty("DocumentTypeIconList")]
public InnerTextConfigurationElement<IconPickerBehaviour> DocumentTypeIconList
{
get { return (InnerTextConfigurationElement<IconPickerBehaviour>)base["DocumentTypeIconList"]; }
get
{
return new OptionalInnerTextConfigurationElement<IconPickerBehaviour>(
(InnerTextConfigurationElement<IconPickerBehaviour>)this["DocumentTypeIconList"],
//set the default
IconPickerBehaviour.HideFileDuplicates);
}
}
[ConfigurationProperty("disallowedUploadFiles")]
public CommaDelimitedConfigurationElement DisallowedUploadFiles
public OptionalCommaDelimitedConfigurationElement DisallowedUploadFiles
{
get { return (CommaDelimitedConfigurationElement)base["disallowedUploadFiles"]; }
get
{
return new OptionalCommaDelimitedConfigurationElement(
(CommaDelimitedConfigurationElement)this["disallowedUploadFiles"],
//set the default
new[] { "ashx", "aspx", "ascx", "config", "cshtml", "vbhtml", "asmx", "air", "axd" });
}
}
[ConfigurationProperty("cloneXmlContent")]

View File

@@ -16,6 +16,10 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
return ((ContentImagingAutoFillUploadFieldElement)element).Alias;
}
internal void Add(ContentImagingAutoFillUploadFieldElement item)
{
BaseAdd(item);
}
IEnumerator<ContentImagingAutoFillUploadFieldElement> IEnumerable<ContentImagingAutoFillUploadFieldElement>.GetEnumerator()
{

View File

@@ -4,7 +4,7 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
{
internal class ContentImagingAutoFillUploadFieldElement : ConfigurationElement
{
[ConfigurationProperty("alias", IsKey = true)]
[ConfigurationProperty("alias", IsKey = true, IsRequired = true)]
internal string Alias
{
get { return (string)this["alias"]; }
@@ -13,25 +13,49 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
[ConfigurationProperty("widthFieldAlias")]
internal InnerTextConfigurationElement<string> WidthFieldAlias
{
get { return (InnerTextConfigurationElement<string>)this["widthFieldAlias"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["widthFieldAlias"],
//set the default
"umbracoWidth");
}
}
[ConfigurationProperty("heightFieldAlias")]
internal InnerTextConfigurationElement<string> HeightFieldAlias
{
get { return (InnerTextConfigurationElement<string>)this["heightFieldAlias"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["heightFieldAlias"],
//set the default
"umbracoHeight");
}
}
[ConfigurationProperty("lengthFieldAlias")]
internal InnerTextConfigurationElement<string> LengthFieldAlias
{
get { return (InnerTextConfigurationElement<string>)this["lengthFieldAlias"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["lengthFieldAlias"],
//set the default
"umbracoBytes");
}
}
[ConfigurationProperty("extensionFieldAlias")]
internal InnerTextConfigurationElement<string> ExtensionFieldAlias
{
get { return (InnerTextConfigurationElement<string>)this["extensionFieldAlias"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["extensionFieldAlias"],
//set the default
"umbracoExtension");
}
}
}
}

View File

@@ -7,20 +7,32 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
[ConfigurationProperty("imageFileTypes")]
internal CommaDelimitedConfigurationElement ImageFileTypes
{
get { return (CommaDelimitedConfigurationElement)this["imageFileTypes"]; }
get
{
return new OptionalCommaDelimitedConfigurationElement(
(CommaDelimitedConfigurationElement)this["imageFileTypes"],
//set the default
new[] { "jpeg", "jpg", "gif", "bmp", "png", "tiff", "tif" });
}
}
[ConfigurationProperty("allowedAttributes")]
internal CommaDelimitedConfigurationElement AllowedAttributes
{
get { return (CommaDelimitedConfigurationElement)this["allowedAttributes"]; }
get
{
return new OptionalCommaDelimitedConfigurationElement(
(CommaDelimitedConfigurationElement)this["allowedAttributes"],
//set the default
new[] { "src", "alt", "border", "class", "style", "align", "id", "name", "onclick", "usemap" });
}
}
[ConfigurationCollection(typeof(ContentImagingAutoFillPropertiesCollection), AddItemName = "uploadField")]
[ConfigurationProperty("autoFillImageProperties", IsDefaultCollection = true)]
[ConfigurationProperty("autoFillImageProperties", IsDefaultCollection = true, IsRequired = true)]
public ContentImagingAutoFillPropertiesCollection ImageAutoFillProperties
{
get { return (ContentImagingAutoFillPropertiesCollection)base["autoFillImageProperties"]; }
get { return (ContentImagingAutoFillPropertiesCollection) base["autoFillImageProperties"]; }
}
}

View File

@@ -7,19 +7,37 @@ namespace Umbraco.Core.Configuration.UmbracoSettings
[ConfigurationProperty("scriptFolderPath")]
internal InnerTextConfigurationElement<string> ScriptFolderPath
{
get { return (InnerTextConfigurationElement<string>)this["scriptFolderPath"]; }
get
{
return new OptionalInnerTextConfigurationElement<string>(
(InnerTextConfigurationElement<string>)this["scriptFolderPath"],
//set the default
"/scripts");
}
}
[ConfigurationProperty("scriptFileTypes")]
internal CommaDelimitedConfigurationElement ScriptFileTypes
internal OptionalCommaDelimitedConfigurationElement ScriptFileTypes
{
get { return (CommaDelimitedConfigurationElement)this["scriptFileTypes"]; }
get
{
return new OptionalCommaDelimitedConfigurationElement(
(OptionalCommaDelimitedConfigurationElement)this["scriptFileTypes"],
//set the default
new[] { "js", "xml" });
}
}
[ConfigurationProperty("scriptDisableEditor")]
internal InnerTextConfigurationElement<bool> DisableScriptEditor
{
get { return (InnerTextConfigurationElement<bool>)this["scriptDisableEditor"]; }
get
{
return new OptionalInnerTextConfigurationElement<bool>(
(InnerTextConfigurationElement<bool>) this["scriptDisableEditor"],
//set the default
false);
}
}
}
}

View File

@@ -0,0 +1,42 @@
using System.Configuration;
namespace Umbraco.Core.Configuration.UmbracoSettings
{
/// <summary>
/// Used for specifying default values for comma delimited config
/// </summary>
internal class OptionalCommaDelimitedConfigurationElement : CommaDelimitedConfigurationElement
{
private readonly CommaDelimitedConfigurationElement _wrapped;
private readonly string[] _defaultValue;
public OptionalCommaDelimitedConfigurationElement()
{
}
public OptionalCommaDelimitedConfigurationElement(CommaDelimitedConfigurationElement wrapped, string[] defaultValue)
{
_wrapped = wrapped;
_defaultValue = defaultValue;
}
public override CommaDelimitedStringCollection Value
{
get
{
if (_wrapped == null)
{
return base.Value;
}
if (string.IsNullOrEmpty(_wrapped.RawValue))
{
var val = new CommaDelimitedStringCollection();
val.AddRange(_defaultValue);
return val;
}
return _wrapped.Value;
}
}
}
}

View File

@@ -180,6 +180,7 @@
<Compile Include="Configuration\UmbracoSettings\NotDynamicXmlDocumentElementCollection.cs" />
<Compile Include="Configuration\UmbracoSettings\NotificationsElement.cs" />
<Compile Include="Configuration\UmbracoSettings\ObjectExtensions.cs" />
<Compile Include="Configuration\UmbracoSettings\OptionalCommaDelimitedConfigurationElement.cs" />
<Compile Include="Configuration\UmbracoSettings\OptionalInnerTextConfigurationElement.cs" />
<Compile Include="Configuration\UmbracoSettings\ProvidersElement.cs" />
<Compile Include="Configuration\UmbracoSettings\RawXmlConfigurationElement.cs" />

View File

@@ -8,11 +8,30 @@ using Umbraco.Core;
namespace Umbraco.Tests.Configurations.UmbracoSettings
{
[TestFixture]
public class ContentElementDefaultTests : ContentElementTests
{
protected override bool TestingDefaults
{
get { return true; }
}
public override void TidyCharEncoding()
{
Assert.IsTrue(Section.Content.TidyCharEncoding == "UTF8");
}
public override void XmlContentCheckForDiskChanges()
{
Assert.IsTrue(Section.Content.XmlContentCheckForDiskChanges == false);
}
}
[TestFixture]
public class ContentElementTests : UmbracoSettingsTests
{
[Test]
public void ScriptFolderPath()
public void UploadAllowDirectories()
{
Assert.IsTrue(Section.Content.UploadAllowDirectories == true);
}
@@ -42,7 +61,7 @@ namespace Umbraco.Tests.Configurations.UmbracoSettings
Assert.IsTrue(Section.Content.TidyEditorContent == false);
}
[Test]
public void TidyCharEncoding()
public virtual void TidyCharEncoding()
{
Assert.IsTrue(Section.Content.TidyCharEncoding == "Raw");
}
@@ -67,7 +86,7 @@ namespace Umbraco.Tests.Configurations.UmbracoSettings
Assert.IsTrue(Section.Content.ContinouslyUpdateXmlDiskCache == true);
}
[Test]
public void XmlContentCheckForDiskChanges()
public virtual void XmlContentCheckForDiskChanges()
{
Assert.IsTrue(Section.Content.XmlContentCheckForDiskChanges == true);
}
@@ -104,7 +123,7 @@ namespace Umbraco.Tests.Configurations.UmbracoSettings
[Test]
public void MacroErrors()
{
Assert.IsTrue(Section.Content.MacroErrors == "inline");
Assert.IsTrue(Section.Content.MacroErrors == MacroErrorBehaviour.Inline);
}
[Test]
public void DocumentTypeIconList()

View File

@@ -3,6 +3,26 @@ using NUnit.Framework;
namespace Umbraco.Tests.Configurations.UmbracoSettings
{
[TestFixture]
public class ContentImagingElementDefaultTests : ContentImagingElementTests
{
protected override bool TestingDefaults
{
get { return true; }
}
[Test]
public override void ImageAutoFillProperties()
{
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.Count == 1);
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).Alias == "umbracoFile");
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).WidthFieldAlias == "umbracoWidth");
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).HeightFieldAlias == "umbracoHeight");
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).LengthFieldAlias == "umbracoBytes");
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).ExtensionFieldAlias == "umbracoExtension");
}
}
[TestFixture]
public class ContentImagingElementTests : UmbracoSettingsTests
{
@@ -17,7 +37,7 @@ namespace Umbraco.Tests.Configurations.UmbracoSettings
Assert.IsTrue(Section.Content.Imaging.AllowedAttributes.All(x => "src,alt,border,class,style,align,id,name,onclick,usemap".Split(',').Contains(x)));
}
[Test]
public void ImageAutoFillProperties()
public virtual void ImageAutoFillProperties()
{
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.Count == 2);
Assert.IsTrue(Section.Content.Imaging.ImageAutoFillProperties.ElementAt(0).Alias == "umbracoFile");

View File

@@ -3,6 +3,15 @@ using NUnit.Framework;
namespace Umbraco.Tests.Configurations.UmbracoSettings
{
[TestFixture]
public class ContentScriptEditorElementDefaultTests : ContentScriptEditorElementTests
{
protected override bool TestingDefaults
{
get { return true; }
}
}
[TestFixture]
public class ContentScriptEditorElementTests : UmbracoSettingsTests
{

View File

@@ -8,16 +8,30 @@ namespace Umbraco.Tests.Configurations.UmbracoSettings
{
public abstract class UmbracoSettingsTests
{
//TODO: Need to test defaults after all this is done.
protected virtual bool TestingDefaults
{
get { return false; }
}
[SetUp]
public void Init()
{
var config = new FileInfo(TestHelper.MapPathForTest("~/Configurations/UmbracoSettings/web.config"));
var fileMap = new ExeConfigurationFileMap() { ExeConfigFilename = config.FullName };
var configuration = ConfigurationManager.OpenMappedExeConfiguration(fileMap, ConfigurationUserLevel.None);
Section = configuration.GetSection("umbracoConfiguration/settings") as UmbracoSettingsSection;
if (TestingDefaults)
{
Section = configuration.GetSection("umbracoConfiguration/defaultSettings") as UmbracoSettingsSection;
}
else
{
Section = configuration.GetSection("umbracoConfiguration/settings") as UmbracoSettingsSection;
}
Assert.IsNotNull(Section);
}

View File

@@ -0,0 +1,199 @@
<?xml version="1.0" encoding="utf-8" ?>
<defaultSettings>
<content>
<imaging>
<autoFillImageProperties>
<uploadField alias="umbracoFile"/>
</autoFillImageProperties>
</imaging>
<errors>
<!-- the id of the page that should be shown if the page is not found -->
<!--<error404>
<errorPage culture="default">1</errorPage>
<errorPage culture="en-US">200</errorPage>
</error404>-->
<error404>
<errorPage culture="default">1047</errorPage>
<errorPage culture="en-US">1048</errorPage>
<errorPage culture="en-UK">1049</errorPage>
</error404>
<!--<error404>1</error404>-->
</errors>
<notifications>
<!-- the email that should be used as from mail when umbraco sends a notification -->
<email>robot@umbraco.dk</email>
</notifications>
</content>
<security>
<!-- set to true to auto update login interval (and there by disabling the lock screen -->
<keepUserLoggedIn>true</keepUserLoggedIn>
<!-- change in 4.8: Disabled users are now showed dimmed and last in the tree. If you prefer not to display them set this to true -->
<hideDisabledUsersInBackoffice>false</hideDisabledUsersInBackoffice>
</security>
<requestHandler>
<!-- this will ensure that urls are unique when running with multiple root nodes -->
<useDomainPrefixes>false</useDomainPrefixes>
<!-- this will add a trailing slash (/) to urls when in directory url mode -->
<addTrailingSlash>true</addTrailingSlash>
<urlReplacing removeDoubleDashes="true">
<char org=" ">-</char>
<char org="&quot;"></char>
<char org="'"></char>
<char org="%"></char>
<char org="."></char>
<char org=";"></char>
<char org="/"></char>
<char org="\"></char>
<char org=":"></char>
<char org="#"></char>
<char org="+">plus</char>
<char org="*">star</char>
<char org="&amp;"></char>
<char org="?"></char>
<char org="æ">ae</char>
<char org="ø">oe</char>
<char org="å">aa</char>
<char org="ä">ae</char>
<char org="ö">oe</char>
<char org="ü">ue</char>
<char org="ß">ss</char>
<char org="Ä">ae</char>
<char org="Ö">oe</char>
<char org="|">-</char>
<char org="&lt;"></char>
<char org="&gt;"></char>
</urlReplacing>
</requestHandler>
<templates>
<useAspNetMasterPages>true</useAspNetMasterPages>
<enableSkinSupport>true</enableSkinSupport>
<defaultRenderingEngine>Mvc</defaultRenderingEngine>
</templates>
<!-- this is used by Umbraco to determine if there's valid classes in the /App_Code folder to be used for Rest/XSLT extensions -->
<developer>
<appCodeFileExtensions>
<ext>cs</ext>
<ext>vb</ext>
</appCodeFileExtensions>
</developer>
<scripting>
<razor>
<!-- razor DynamicNode typecasting detects XML and returns DynamicXml - Root elements that won't convert to DynamicXml -->
<notDynamicXmlDocumentElements>
<element>p</element>
<element>div</element>
<element>ul</element>
<element>span</element>
</notDynamicXmlDocumentElements>
<dataTypeModelStaticMappings>
<mapping dataTypeGuid="A3DB4034-BCB0-4E69-B3EE-DD4E6ECA74C2">MyName.1</mapping>
<mapping documentTypeAlias="textPage2" nodeTypeAlias="propertyAlias2">MyName.2</mapping>
<mapping dataTypeGuid="BD14E709-45BE-431C-B228-6255CDEDFCD5" documentTypeAlias="textPage3" nodeTypeAlias="propertyAlias3">MyName.3</mapping>
<mapping dataTypeGuid="FCE8187E-0366-4833-953A-E5ECA11AA23A" documentTypeAlias="textPage4">MyName.4</mapping>
<mapping dataTypeGuid="9139315A-6681-4C45-B89F-BE48D30F9AB9" nodeTypeAlias="propertyAlias5">MyName.5</mapping>
<mapping nodeTypeAlias="propertyAlias6">MyName.6</mapping>
</dataTypeModelStaticMappings>
</razor>
</scripting>
<viewstateMoverModule enable="false" />
<logging>
<autoCleanLogs>false</autoCleanLogs>
<enableLogging>true</enableLogging>
<enableAsyncLogging>true</enableAsyncLogging>
<disabledLogTypes>
<logTypeAlias>[alias-of-log-type-in-lowercase]</logTypeAlias>
<logTypeAlias>anotherlogalias</logTypeAlias>
</disabledLogTypes>
<cleaningMiliseconds>86400</cleaningMiliseconds>
<maxLogAge>1440</maxLogAge>
<externalLogger assembly="~/bin/assemblyFileName.dll" type="fully.qualified.namespace.and.type" logAuditTrail="false" />
</logging>
<scheduledTasks>
<!-- add tasks that should be called with an interval (seconds) -->
<task log="true" alias="test60" interval="60" url="http://localhost/umbraco/test.aspx"/>
<task log="false" alias="testtest" interval="61" url="http://localhost/umbraco/test1.aspx"/>
</scheduledTasks>
<!-- distributed calls make umbraco use webservices to handle cache refreshing -->
<distributedCall enable="true">
<!-- the id of the user who's making the calls -->
<!-- needed for security, umbraco will automatically look up correct login and passwords -->
<user>0</user>
<servers>
<!-- add ip number or hostname, make sure that it can be reached from all servers -->
<!-- you can also add optional attributes to force a protocol or port number (see #2) -->
<server>127.0.0.1</server>
<server forceProtocol="https" forcePortnumber="443">127.0.0.2</server>
</servers>
</distributedCall>
<!-- configuration for webservices -->
<!-- webservices are disabled by default. Set enable="True" to enable them -->
<webservices enabled="True">
<!-- You must set user-rights for each service. Enter the usernames seperated with comma (,) -->
<templateServiceUsers>your-username5</templateServiceUsers>
<documentServiceUsers>your-username1</documentServiceUsers>
<fileServiceUsers>your-username2</fileServiceUsers>
<stylesheetServiceUsers>your-username3</stylesheetServiceUsers>
<memberServiceUsers>your-username4</memberServiceUsers>
<mediaServiceUsers>your-username6</mediaServiceUsers>
<!-- type of files (extensions) that are allowed for the file service -->
<fileServiceFolders>css,xslt</fileServiceFolders>
</webservices>
<!-- Configuration for repositories -->
<!-- Add or remove repositories here. You will need the repository's unique key to be able to connect to it.-->
<repositories>
<repository name="Umbraco package Repository" guid="65194810-1f85-11dd-bd0b-0800200c9a66" />
<repository name="Test Repo" guid="163245E0-CD22-44B6-841A-1B9B9D2E955F" />
</repositories>
<providers>
<users>
<!-- if you wish to use your own membershipprovider for authenticating to the umbraco back office -->
<!-- specify it here (remember to add it to the web.config as well) -->
<DefaultBackofficeProvider>UsersMembershipProvider</DefaultBackofficeProvider>
</users>
</providers>
<!-- Maps language, usertype, application and application_url to help pages -->
<help defaultUrl="http://our.umbraco.org/wiki/umbraco-help/{0}/{1}">
<!-- Add links that should open custom help pages -->
<link application="content" applicationUrl="dashboard.aspx" language="en" userType="Administrators" helpUrl="http://www.xyz.no?{0}/{1}/{2}/{3}" />
<link application="media" applicationUrl="dashboard2.aspx" language="ch" userType="Writers" helpUrl="http://www.abc.no?{0}/{1}/{2}/{3}" />
</help>
<!--
web.routing
@trySkipIisCustomErrors
Tries to skip IIS custom errors.
Starting with IIS 7.5, this must be set to true for Umbraco 404 pages to show. Else, IIS will take
over and render its build-in error page. See MS doc for HttpResponseBase.TrySkipIisCustomErrors.
The default value is false, for backward compatibility reasons, which means that IIS _will_ take
over, and _prevent_ Umbraco 404 pages to show.
@internalRedirectPreservesTemplate
By default as soon as we're not displaying the initial document, we reset the template set by the
finder or by the alt. template. Set this option to true to preserve the template set by the finder
or by the alt. template, in case of an internal redirect.
(false by default, and in fact should remain false unless you know what you're doing)
-->
<web.routing
trySkipIisCustomErrors="false"
internalRedirectPreservesTemplate="false">
</web.routing>
</defaultSettings>

View File

@@ -4,11 +4,13 @@
<configSections>
<sectionGroup name="umbracoConfiguration">
<section name="settings" type="Umbraco.Core.Configuration.UmbracoSettings.UmbracoSettingsSection, Umbraco.Core" requirePermission="false" />
<section name="defaultSettings" type="Umbraco.Core.Configuration.UmbracoSettings.UmbracoSettingsSection, Umbraco.Core" requirePermission="false" />
</sectionGroup>
</configSections>
<umbracoConfiguration>
<settings configSource="umbracoSettings.config" />
<defaultSettings configSource="umbracoSettings.minimal.config" />
</umbracoConfiguration>
</configuration>

View File

@@ -449,6 +449,10 @@
<None Include="App.config">
<SubType>Designer</SubType>
</None>
<None Include="Configurations\UmbracoSettings\umbracoSettings.minimal.config">
<SubType>Designer</SubType>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="Configurations\UmbracoSettings\umbracoSettings.config">
<SubType>Designer</SubType>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>