Skip to content

Commit

Permalink
Change EntryMember record type to AttributeType
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuvindu committed Jun 25, 2024
1 parent 72b1546 commit 6f13840
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions ballerina/tests/test.bal
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ final Client ldapClient = check new ({
groups: ["add"]
}
public function testAddUser() returns error? {
record {|EntryMember...;|} user = {
record {|AttributeType...;|} user = {
"objectClass": ["top", "person"],
"sn": "User",
"cn": "User"
Expand All @@ -48,7 +48,7 @@ public function testAddUser() returns error? {
dependsOn: [testAddUser]
}
public function testAddSecondaryUser() returns error? {
record {|EntryMember...;|} user = {
record {|AttributeType...;|} user = {
"objectClass": ["top", "person"],
"sn": "New User",
"cn": "New User"
Expand Down Expand Up @@ -94,7 +94,7 @@ public function testAddAlreadyExistingUser() returns error? {
dependsOn: [testAddAlreadyExistingUser]
}
public function testUpdateUser() returns error? {
record {|EntryMember...;|} user = {
record {|AttributeType...;|} user = {
"sn": "Updated User"
};
LdapResponse response = check ldapClient->modify(userDN, user);
Expand Down
4 changes: 2 additions & 2 deletions ballerina/tests/types.bal
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ type UserConfig record {
string userAccountControl?;
};

record {|EntryMember...;|} user = {
record {|AttributeType...;|} user = {
"sn": "Timothy",
"objectClass": ["person", "top"]
};

record {|EntryMember...;|} updateUser = {
record {|AttributeType...;|} updateUser = {
"objectClass": ["person", "top"],
"sn": "Updated User"
};
4 changes: 2 additions & 2 deletions ballerina/types.bal
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ public enum SearchScope {
};

# Attribute type of an LDAP entry.
public type EntryMember boolean|int|float|decimal|string|string[];
public type AttributeType boolean|int|float|decimal|string|string[];

# LDAP entry type.
public type Entry record{|EntryMember...;|};
public type Entry record{|AttributeType...;|};

# A record for an entry that represents a person.
#
Expand Down

0 comments on commit 6f13840

Please sign in to comment.