diff --git a/include/faker-cxx/types/Language.h b/include/faker-cxx/types/Language.h index acffd9160..045c198bc 100644 --- a/include/faker-cxx/types/Language.h +++ b/include/faker-cxx/types/Language.h @@ -15,14 +15,17 @@ enum class Language Romanian, Hindi, Finnish, + Nepali, }; inline std::string toString(Language language) { std::map languageToStringMapping{ - {Language::English, "English"} , {Language::Polish, "Polish"}, {Language::Italian, "Italian"}, - {Language::French, "French"} , {Language::German, "German"}, {Language::Russian, "Russian"}, - {Language::Romanian, "Romanian"}, {Language::Hindi, "Hindi"}, {Language::Finnish, "Finnish"}}; + {Language::English, "English"}, {Language::Polish, "Polish"}, {Language::Italian, "Italian"}, + {Language::French, "French"}, {Language::German, "German"}, {Language::Russian, "Russian"}, + {Language::Romanian, "Romanian"}, {Language::Hindi, "Hindi"}, {Language::Finnish, "Finnish"}, + {Language::Nepali, "Nepali"}, + }; return languageToStringMapping.at(language); } diff --git a/src/modules/person/Person.cpp b/src/modules/person/Person.cpp index b0b020cac..ccb976152 100644 --- a/src/modules/person/Person.cpp +++ b/src/modules/person/Person.cpp @@ -22,6 +22,9 @@ #include "data/italian/ItalianFirstNamesMales.h" #include "data/italian/ItalianLastNames.h" #include "data/JobTitles.h" +#include "data/nepalese/NepaleseFirstNamesFemales.h" +#include "data/nepalese/NepaleseFirstNamesMales.h" +#include "data/nepalese/NepaleseLastNames.h" #include "data/polish/PolishFirstNamesFemales.h" #include "data/polish/PolishFirstNamesMales.h" #include "data/polish/PolishLastNames.h" @@ -54,6 +57,7 @@ const std::map>> languageToFirs {Language::Romanian, {{Sex::Male, romanianFirstNamesMales}, {Sex::Female, romanianFirstNamesFemales}}}, {Language::Hindi, {{Sex::Male, indianFirstNamesMales}, {Sex::Female, indianFirstNamesFemales}}}, {Language::Finnish, {{Sex::Male, finnishFirstNamesMales}, {Sex::Female, finnishFirstNamesFemales}}}, + {Language::Nepali, {{Sex::Male, nepaleseFirstNamesMales}, {Sex::Female, nepaleseFirstNamesFemales}}}, }; const std::map>> languageToLastNamesMapping{ @@ -66,6 +70,7 @@ const std::map>> languageToLast {Language::Romanian, {{Sex::Male, romanianLastNames}, {Sex::Female, romanianLastNames}}}, {Language::Hindi, {{Sex::Male, indianLastNames}, {Sex::Female, indianLastNames}}}, {Language::Finnish, {{Sex::Male, finnishLastNames}, {Sex::Female, finnishLastNames}}}, + {Language::Nepali, {{Sex::Male, nepaleseLastNames}, {Sex::Female, nepaleseLastNames}}}, }; } diff --git a/src/modules/person/PersonTest.cpp b/src/modules/person/PersonTest.cpp index dab912bb6..e58a81137 100644 --- a/src/modules/person/PersonTest.cpp +++ b/src/modules/person/PersonTest.cpp @@ -35,6 +35,9 @@ #include "data/russian/RussianLastNamesFemales.h" #include "data/russian/RussianLastNamesMales.h" #include "src/common/StringHelper.h" +#include "src/modules/person/data/nepalese/NepaleseFirstNamesFemales.h" +#include "src/modules/person/data/nepalese/NepaleseFirstNamesMales.h" +#include "src/modules/person/data/nepalese/NepaleseLastNames.h" using namespace ::testing; using namespace faker; @@ -45,9 +48,10 @@ const auto malePrefix{"Mr."}; const std::vector femalePrefixes{"Ms.", "Miss"}; const std::vector allPrefixes{"Mr.", "Ms.", "Miss"}; -const std::vector languages{Language::English, Language::French, Language::German, - Language::Italian, Language::Polish, Language::Russian, - Language::Romanian, Language::Hindi, Language::Finnish}; +const std::vector languages{ + Language::English, Language::French, Language::German, Language::Italian, Language::Polish, + Language::Russian, Language::Romanian, Language::Hindi, Language::Finnish, Language::Nepali, +}; const std::map>> languageToFirstNamesMapping{ {Language::English, {{Sex::Male, englishFirstNamesMales}, {Sex::Female, englishFirstNamesFemales}}}, @@ -59,6 +63,7 @@ const std::map>> languageToFirs {Language::Romanian, {{Sex::Male, romanianFirstNamesMales}, {Sex::Female, romanianFirstNamesFemales}}}, {Language::Hindi, {{Sex::Male, indianFirstNamesMales}, {Sex::Female, indianFirstNamesFemales}}}, {Language::Finnish, {{Sex::Male, finnishFirstNamesMales}, {Sex::Female, finnishFirstNamesFemales}}}, + {Language::Nepali, {{Sex::Male, nepaleseFirstNamesMales}, {Sex::Female, nepaleseFirstNamesFemales}}}, }; const std::map>> languageToLastNamesMapping{ @@ -71,6 +76,7 @@ const std::map>> languageToLast {Language::Romanian, {{Sex::Male, romanianLastNames}, {Sex::Female, romanianLastNames}}}, {Language::Hindi, {{Sex::Male, indianLastNames}, {Sex::Female, indianLastNames}}}, {Language::Finnish, {{Sex::Male, finnishLastNames}, {Sex::Female, finnishLastNames}}}, + {Language::Nepali, {{Sex::Male, nepaleseLastNames}, {Sex::Female, nepaleseLastNames}}}, }; const std::map generatedTestName{ @@ -78,7 +84,7 @@ const std::map generatedTestName{ {Language::German, "shouldGenerateGermanName"}, {Language::Italian, "shouldGenerateItalianName"}, {Language::Polish, "shouldGeneratePolishName"}, {Language::Russian, "shouldGenerateRussianName"}, {Language::Romanian, "shouldGenerateRomanianName"}, {Language::Hindi, "shouldGenerateIndianName"}, - {Language::Finnish, "shouldGenerateFinnishName"}, + {Language::Finnish, "shouldGenerateFinnishName"}, {Language::Nepali, "shouldGenerateNepaleseName"}, }; } @@ -325,4 +331,4 @@ TEST_F(PersonTest, shouldGenerateHobby) ASSERT_TRUE( std::ranges::any_of(hobbies, [generatedHobby](const std::string& hobby) { return hobby == generatedHobby; })); -} \ No newline at end of file +} diff --git a/src/modules/person/data/nepalese/NepaleseFirstNamesFemales.h b/src/modules/person/data/nepalese/NepaleseFirstNamesFemales.h new file mode 100644 index 000000000..76c28bf3e --- /dev/null +++ b/src/modules/person/data/nepalese/NepaleseFirstNamesFemales.h @@ -0,0 +1,25 @@ +#pragma once + +#include +#include + +namespace faker +{ +const std::vector nepaleseFirstNamesFemales = { + + "Sita", "Gita", "Shristi", "Anita", "Priya", "Sabina", "Nisha", "Saraswati", + "Asha", "Binita", "Deepa", "Kamala", "Laxmi", "Rina", "Bishnu", "Meera", + "Sushma", "Pooja", "Rajani", "Sunita", "Nirmala", "Rita", "Sumitra", "Usha", + "Manisha", "Rekha", "Sarita", "Kusum", "Puja", "Sanjana", "Smriti", "Pratima", + "Sabita", "Kanchan", "Nandita", "Anjali", "Harsha", "Sangita", "Sushmita", "Suman", + "Sweta", "Sadhana", "Anju", "Nabina", "Bhawana", "Srijana", "Nikita", "Aarati", + "Anita", "Nitu", "Sima", "Sita", "Goma", "Sarala", "Sarika", "Sabita", + "Madhavi", "Indira", "Ankita", "Bhumika", "Neha", "Ashmita", "Subiksha", "Supriya", + "Urmila", "Shova", "Shruti", "Ruby", "Samjhana", "Prakriti", "Ashika", "Reecha", + "Yamuna", "Sunaina", "Sujata", "Muna", "Sulochana", "Jamuna", "Anshu", "Sarala", + "Sarika", "Puspa", "Manju", "Sadhana", "Pabitra", "Usha", "Manita", "Rekha", + "Swastika", "Priyanka", "Sharmila", "Manju", "Sudha", "Laxmi", "Sunita", "Tulsi", + "Usha", "Saraswati", "Rachana" + +}; +} diff --git a/src/modules/person/data/nepalese/NepaleseFirstNamesMales.h b/src/modules/person/data/nepalese/NepaleseFirstNamesMales.h new file mode 100644 index 000000000..d1e65ef2a --- /dev/null +++ b/src/modules/person/data/nepalese/NepaleseFirstNamesMales.h @@ -0,0 +1,25 @@ +#pragma once + +#include +#include + +namespace faker +{ + +const std::vector nepaleseFirstNamesMales = { + + "Sijan", "Prabesh", "Niwang", "Nabin", "Sanjok", "Bibek", "Sujal", "Sagar", "Mukunda", "Arun", + "Nirdesh", "Rabin", "Ramesh", "Manoj", "Bimal", "Anil", "Bipin", "Gopal", "Sunil", "Bikash", + "Sujan", "Sudeep", "Nikhil", "Nishant", "Kiran", "Pramod", "Saroj", "Rajesh", "Dilip", "Sandesh", + "Krishna", "Hari", "Suresh", "Arjun", "Bibash", "Rajiv", "Rajendra", "Bijay", "Aashish", "Raju", + "Sabin", "Keshav", "Rabi", "Sanjeev", "Puspa", "Saroj", "Khem", "Shiva", "Mohan", "Dinesh", + "Rajendra", "Suman", "Ujjwal", "Bhuwan", "Birendra", "Birat", "Lalit", "Bhola", "Pradip", "Nabin", + "Suman", "Shankar", "Laxman", "Sushant", "Roshan", "Buddha", "Kapil", "Rajbir", "Suraj", "Raj Kumar", + "Manish", "Ajay", "Dipak", "Anish", "Sabin", "Prem", "Bijay", "Narayan", "Rajat", "Rishi", + "Yogesh", "Rajendra", "Pawan", "Bhawesh", "Pramod", "Pramod", "Saurav", "Hemant", "Subash", "Sparsha", + "Sabin", "Manohar", "Anuj", "Aryan", "Yogendra", "Nischal", "Samir", "Sanjay", "Bijay", "Rohit", + "Rajat", "Biraj", "Kiran", "Pravin", "Pramod" + +}; + +} diff --git a/src/modules/person/data/nepalese/NepaleseLastNames.h b/src/modules/person/data/nepalese/NepaleseLastNames.h new file mode 100644 index 000000000..360a31218 --- /dev/null +++ b/src/modules/person/data/nepalese/NepaleseLastNames.h @@ -0,0 +1,20 @@ +#pragma once + +#include +#include + +namespace faker +{ + +const std::vector nepaleseLastNames = { + "Adhikari", "Bhattarai", "Gurung", "Tamang", "Magar", "Shrestha", "Rai", "Limbu", "Poudel", + "Joshi", "Karki", "Shah", "Thapa", "Rana", "Regmi", "Acharya", "Basnet", "Shrestha", + "Lama", "Khadka", "Maharjan", "Panta", "Sherpa", "Lohani", "Giri", "Gupta", "Mishra", + "Chhetri", "Magar", "Parajuli", "Dhakal", "Malla", "Gyawali", "Pariyar", "Thakuri", "Roka", + "Sapkota", "Waiba", "Pariyar", "Chand", "Subedi", "Ghimere", "Khatri", "Bista", "Bajracharya", + "Dhungana", "Budhathoki", "Yadav", "Rokaya", "Chaudhary", "Pathak", "Pandey", "Baniya", "Devkota", + "Dangol", "Koirala", "Mishra", "Oli", "Sherchan", "Rajbanshi", "Bhandari", "Niroula", "Nepal", + "Nepali" + +}; +}