-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #188 from neelsmith/dev
Update for new signature of `strcat`
- Loading branch information
Showing
10 changed files
with
96 additions
and
98 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,28 @@ | ||
@testset "Simulate phonology used in morphological generation" begin | ||
o = literaryGreek() | ||
|
||
ex1 = strcat("λυ", "ει", o) | ||
ex1 = strcat(o, "λυ", "ει") | ||
@test ex1 == "λυει" | ||
@test accentword(ex1,:RECESSIVE, o) == "λύει" | ||
@test accentword(ex1,:RECESSIVE) == "λύει" | ||
|
||
dupe = reduplicate("λυ", o) | ||
@test dupe == "λελυ" | ||
@test accentword(strcat(dupe, "κε", o), :RECESSIVE, o) == "λέλυκε" | ||
@test accentword(strcat(o, dupe, "κε"), :RECESSIVE) == "λέλυκε" | ||
|
||
aug = augment("λυ", o) | ||
@test aug == "ἐλυ" | ||
@test accentword(strcat(aug, "ομεθα",o), :RECESSIVE, o) == "ἐλυόμεθα" | ||
@test accentword(strcat(o, aug, "ομεθα"), :RECESSIVE) == "ἐλυόμεθα" | ||
|
||
ex2 = strcat("ἀνα#λυ", "ει", o) | ||
ex2 = strcat(o, "ἀνα#λυ", "ει") | ||
@test ex2 == "ἀνα#λυει" | ||
@test accentword(ex2,:RECESSIVE, o) == "ἀναλύει" | ||
@test accentword(ex2,:RECESSIVE) == "ἀναλύει" | ||
|
||
dupe2 = reduplicate("ἀνα#λυ", o) | ||
@test dupe2 == "ἀνα#λελυ" | ||
@test accentword(strcat(dupe2, "κε", o), :RECESSIVE, o) == "ἀναλέλυκε" | ||
@test accentword(strcat(o, dupe2, "κε"), :RECESSIVE) == "ἀναλέλυκε" | ||
|
||
aug2 = augment("ἀνα#λυ", o) | ||
@test aug2 == "ἀν#ελυ" | ||
@test accentword(strcat(aug2, "ομεθα",o), :RECESSIVE, o) == "ἀνελυόμεθα" | ||
@test accentword(strcat(o, aug2, "ομεθα"), :RECESSIVE) == "ἀνελυόμεθα" | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,104 +1,103 @@ | ||
@testset "Test concatenating strings for literary Greek" begin | ||
ortho = literaryGreek() | ||
|
||
@test strcat("λελειπ", "μαι", ortho) == "λελειμμαι" | ||
@test strcat("λελειπ", "σαι", ortho) == "λελειψαι" | ||
@test strcat("λελειπ", "ται", ortho) == "λελειπται" | ||
@test strcat(ortho, "λελειπ", "μαι") == "λελειμμαι" | ||
@test strcat(ortho, "λελειπ", "σαι") == "λελειψαι" | ||
@test strcat(ortho, "λελειπ", "ται") == "λελειπται" | ||
|
||
@test strcat("τετριβ", "μαι", ortho) == "τετριμμαι" | ||
@test strcat("τετριβ", "σαι", ortho) == "τετριψαι" | ||
@test strcat("τετριβ", "ται", ortho) == "τετριπται" | ||
@test strcat(ortho, "τετριβ", "μαι") == "τετριμμαι" | ||
@test strcat(ortho, "τετριβ", "σαι") == "τετριψαι" | ||
@test strcat(ortho, "τετριβ", "ται") == "τετριπται" | ||
|
||
|
||
@test strcat("γεγραφ", "μαι", ortho) == "γεγραμμαι" | ||
@test strcat("γεγραφ", "σαι", ortho) == "γεγραψαι" | ||
@test strcat("γεγραφ", "ται", ortho) == "γεγραπται" | ||
@test strcat(ortho, "γεγραφ", "μαι") == "γεγραμμαι" | ||
@test strcat(ortho, "γεγραφ", "σαι") == "γεγραψαι" | ||
@test strcat(ortho, "γεγραφ", "ται") == "γεγραπται" | ||
|
||
|
||
@test strcat("πεπλεκ", "μαι", ortho) == "πεπλεγμαι" | ||
@test strcat("πεπλεκ", "σαι", ortho) == "πεπλεξαι" | ||
@test strcat("πεπλεκ", "ται", ortho) == "πεπλεκται" | ||
@test strcat(ortho, "πεπλεκ", "μαι") == "πεπλεγμαι" | ||
@test strcat(ortho, "πεπλεκ", "σαι") == "πεπλεξαι" | ||
@test strcat(ortho, "πεπλεκ", "ται") == "πεπλεκται" | ||
|
||
@test strcat("λελεγ", "μαι", ortho) == "λελεγμαι" | ||
@test strcat("λελεγ", "σαι", ortho) == "λελεξαι" | ||
@test strcat("λελεγ", "ται", ortho) == "λελεκται" | ||
@test strcat(ortho, "λελεγ", "μαι") == "λελεγμαι" | ||
@test strcat(ortho, "λελεγ", "σαι") == "λελεξαι" | ||
@test strcat(ortho, "λελεγ", "ται") == "λελεκται" | ||
|
||
@test strcat("βεβρεχ", "μαι", ortho) == "βεβρεγμαι" | ||
@test strcat("βεβρεχ", "σαι", ortho) == "βεβρεξαι" | ||
@test strcat("βεβρεχ", "ται", ortho) == "βεβρεκται" | ||
@test strcat(ortho, "βεβρεχ", "μαι") == "βεβρεγμαι" | ||
@test strcat(ortho, "βεβρεχ", "σαι") == "βεβρεξαι" | ||
@test strcat(ortho, "βεβρεχ", "ται") == "βεβρεκται" | ||
|
||
|
||
@test strcat("πεπειθ", "ται", ortho) == "πεπεισται" | ||
@test strcat(ortho, "πεπειθ", "ται") == "πεπεισται" | ||
|
||
@test strcat("λειπ", "σω", ortho) == "λειψω" | ||
@test strcat("τριβ", "σω", ortho) == "τριψω" | ||
@test strcat("γραφ", "σω", ortho) == "γραψω" | ||
@test strcat(ortho, "λειπ", "σω") == "λειψω" | ||
@test strcat(ortho, "τριβ", "σω") == "τριψω" | ||
@test strcat(ortho, "γραφ", "σω") == "γραψω" | ||
|
||
|
||
@test strcat("ἐν","πιπτω", ortho) == "ἐμπιπτω" | ||
@test strcat("ἐν","βαλλω", ortho) == "ἐμβαλλω" | ||
@test strcat("ἐν","φαινω", ortho) == "ἐμφαινω" | ||
@test strcat(ortho, "ἐν","πιπτω") == "ἐμπιπτω" | ||
@test strcat(ortho, "ἐν","βαλλω") == "ἐμβαλλω" | ||
@test strcat(ortho, "ἐν","φαινω") == "ἐμφαινω" | ||
|
||
@test strcat("ἐν","καλεω", ortho) == "ἐγκαλεω" | ||
@test strcat("ἐν","γραφω", ortho) == "ἐγγραφω" | ||
@test strcat("συν","χεω", ortho) == "συγχεω" | ||
@test strcat("συν","ξυω", ortho) == "συγξυω" | ||
@test strcat(ortho, "ἐν","καλεω") == "ἐγκαλεω" | ||
@test strcat(ortho, "ἐν","γραφω") == "ἐγγραφω" | ||
@test strcat(ortho, "συν","χεω") == "συγχεω" | ||
@test strcat(ortho, "συν","ξυω") == "συγξυω" | ||
|
||
@test strcat("ἐν","μενω", ortho) == "ἐμμενω" | ||
@test strcat(ortho, "ἐν","μενω") == "ἐμμενω" | ||
|
||
@test strcat("συν","λογος", ortho) == "συλλογος" | ||
@test strcat("συν","ρεω", ortho) == "συρρεω" | ||
@test strcat(ortho, "συν","λογος") == "συλλογος" | ||
@test strcat(ortho, "συν","ρεω") == "συρρεω" | ||
|
||
|
||
@test strcat("δεικ","σ", ortho) == "δειξ" | ||
@test strcat(ortho, "δεικ","σ") == "δειξ" | ||
|
||
@test strcat("συν","οἰσω", ortho) == "συνοισω" | ||
@test strcat(ortho, "συν","οἰσω") == "συνοισω" | ||
|
||
@test strcat("περι","οἰσω", ortho) == "περιοισω" | ||
@test strcat(ortho, "περι","οἰσω") == "περιοισω" | ||
|
||
@test strcat("προ","ἠγγελλε", ortho) == "προηγγελλε" | ||
@test strcat(ortho, "προ","ἠγγελλε") == "προηγγελλε" | ||
|
||
@test strcat("κατα","ἀγγελλω", ortho, elision = true) == "καταγγελλω" | ||
@test strcat(ortho, "κατα","ἀγγελλω", elision = true) == "καταγγελλω" | ||
|
||
|
||
@test strcat("κατα","αἱρεω", ortho, elision = true) == "καθαιρεω" | ||
@test strcat(ortho, "κατα","αἱρεω", elision = true) == "καθαιρεω" | ||
|
||
end | ||
|
||
#= | ||
@testset "Test working with compounds" begin | ||
pieces = split("παρα#ἐκ#εν#φέρω","#") | ||
@test_broken strcat(literaryGreek(), pieces...) == nfkc("παρεξεν#φέρω") | ||
@test strcat(literaryGreek(), nfkc("ἐν"), nfkc("κελεύω")) == nfkc("ἐγκελεύω") | ||
@test strcat(literaryGreek(), nfkc("ἐν"), "κε", nfkc("λεύ"), "ω") == nfkc("ἐγκελεύω") | ||
end | ||
=# | ||
|
||
|
||
|
||
@testset "Test phonology of perfect active consonants" begin | ||
ortho = literaryGreek() | ||
|
||
@test strcat("γεγραπ", "μαι", ortho) == "γεγραμμαι" | ||
@test strcat("γεγραπ", "σαι", ortho) == "γεγραψαι" | ||
@test strcat("γεγραπ", "ται", ortho) == "γεγραπται" | ||
@test strcat(ortho,"γεγραπ", "μαι") == "γεγραμμαι" | ||
@test strcat(ortho,"γεγραπ", "σαι") == "γεγραψαι" | ||
@test strcat(ortho,"γεγραπ", "ται") == "γεγραπται" | ||
|
||
@test strcat("γεγραπ", "μεθα", ortho) == "γεγραμμεθα" | ||
@test strcat("γεγραπ", "σθε", ortho) == "γεγραφθε" | ||
@test strcat(ortho,"γεγραπ", "μεθα") == "γεγραμμεθα" | ||
@test strcat(ortho,"γεγραπ", "σθε") == "γεγραφθε" | ||
|
||
|
||
@test strcat("γεγραφ", "μαι", ortho) == "γεγραμμαι" | ||
@test strcat("γεγραφ", "σαι", ortho) == "γεγραψαι" | ||
@test strcat("γεγραφ", "ται", ortho) == "γεγραπται" | ||
@test strcat(ortho,"γεγραφ", "μαι") == "γεγραμμαι" | ||
@test strcat(ortho,"γεγραφ", "σαι") == "γεγραψαι" | ||
@test strcat(ortho,"γεγραφ", "ται") == "γεγραπται" | ||
|
||
@test strcat("γεγραφ", "μεθα", ortho) == "γεγραμμεθα" | ||
@test strcat("γεγραφ", "σθε", ortho) == "γεγραφθε" | ||
@test strcat(ortho,"γεγραφ", "μεθα") == "γεγραμμεθα" | ||
@test strcat(ortho,"γεγραφ", "σθε") == "γεγραφθε" | ||
|
||
|
||
@test strcat("πεπραγ", "μαι", ortho) == "πεπραγμαι" | ||
@test strcat("πεπραγ", "σαι", ortho) == "πεπραξαι" | ||
@test strcat("πεπραγ", "ται", ortho) == "πεπρακται" | ||
@test strcat(ortho,"πεπραγ", "μαι") == "πεπραγμαι" | ||
@test strcat(ortho,"πεπραγ", "σαι") == "πεπραξαι" | ||
@test strcat(ortho,"πεπραγ", "ται") == "πεπρακται" | ||
|
||
@test strcat("πεπραγ", "μεθα", ortho) == "πεπραγμεθα" | ||
@test strcat("πεπραγ", "σθε", ortho) == "πεπραχθε" | ||
@test strcat(ortho,"πεπραγ", "μεθα") == "πεπραγμεθα" | ||
@test strcat(ortho,"πεπραγ", "σθε") == "πεπραχθε" | ||
|
||
@test strcat("ἐβη", "", ortho) == "ἐβη" | ||
@test strcat(ortho,"ἐβη", "") == "ἐβη" | ||
|
||
end |