Skip to content

Commit

Permalink
more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lmajano committed Aug 30, 2019
1 parent ed996de commit af147fe
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 0 deletions.
40 changes: 40 additions & 0 deletions test-harness/modules_app/test1/ModuleConfig.cfc
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<cfcomponent output="false" hint="My App Configuration">
<cfscript>
// Module Properties
this.title = "My Test Module";
this.author = "Luis Majano";
this.webURL = "http://www.coldbox.org";
this.description = "A funky test module";
// If true, looks for views in the parent first, if not found, then in the module. Else vice-versa
this.viewParentLookup = true;
// If true, looks for layouts in the parent first, if not found, then in module. Else vice-versa
this.layoutParentLookup = true;
this.entryPoint = "test1";
// CFML Mapping for this module, the path will be the module root. If empty, none is registered.
this.cfmapping = "test1";

function configure(){

// SES Routes
routes = [
{ pattern="/", handler="test",action="index" },
{ pattern="/:handler/:action?" }
];

// i18n
i18n = {
defaultLocale = "es_SV",
resourceBundles = {
"module@test1" = "#moduleMapping#/includes/module"
}
};

}

function onLoad(){
}

function onUnload(){
}
</cfscript>
</cfcomponent>
13 changes: 13 additions & 0 deletions test-harness/modules_app/test1/handlers/test.cfc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/**
* My Event Handler Hint
*/
component{

/**
* i18n
*/
any function i18n(event,rc,prc){
return "<h2>i18n from module: #getResource( resource="welcome", bundle="module@test1" )#</h2>";
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@

welcome = Welcome to my awesome multi-lingual module
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#Generated by ResourceBundle Editor (http://eclipse-rbe.sourceforge.net)

welcome = Bienvenido a mi modulo multi-lenguajes

0 comments on commit af147fe

Please sign in to comment.