Rework the multilingual docs

And in the same go adjusted some minor parts of the language API:

Add LanguagePrefix alias to Node and rename the Multilingual config section to Languages.

See #2309
This commit is contained in:
Bjørn Erik Pedersen
2016-08-04 12:06:29 +02:00
parent ed0985404d
commit f0b91852ea
5 changed files with 51 additions and 168 deletions

View File

@@ -48,7 +48,7 @@ func testCommonResetState() {
}
func _TestMultiSites(t *testing.T) {
func TestMultiSites(t *testing.T) {
sites := createMultiTestSites(t)
@@ -65,7 +65,7 @@ func _TestMultiSites(t *testing.T) {
if len(enSite.Pages) != 3 {
t.Fatal("Expected 3 english pages")
}
assert.Len(t, enSite.Source.Files(), 6, "should have 6 source files")
assert.Len(t, enSite.Source.Files(), 11, "should have 11 source files")
assert.Len(t, enSite.AllPages, 6, "should have 6 total pages (including translations)")
doc1en := enSite.Pages[0]