Skip to content

Commit

Permalink
Added a testcase for getUserRoles() function
Browse files Browse the repository at this point in the history
  • Loading branch information
cfmitrah committed Aug 25, 2023
1 parent d321163 commit a8723d3
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions test/functions/GetUserRoles.cfc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
component extends="org.lucee.cfml.test.LuceeTestCase" {

function run( testResults, testBox ) {
describe( title = "Testcase for getUserRoles() function", body = function() {
it( title = "Checking getUserRoles() function", body = function( currentSpec ) {
```
<cflogin>
<cfloginuser name = "test" password = "password" roles = "user,admin,editor">
</cflogin>
```
expect(getUserRoles()).toBe("user,admin,editor");
});
});
}
}

0 comments on commit a8723d3

Please sign in to comment.