WpUser additional specs

This commit is contained in:
erwanlr
2013-03-30 19:08:47 +01:00
parent 21f5acf62f
commit a9b25edafe
5 changed files with 53 additions and 6 deletions

View File

@@ -7,6 +7,7 @@ class WpUser < WpItem
attr_accessor :id, :login, :display_name, :password
# @return [ Array<Symbol> ]
def allowed_options; [:id, :login, :display_name, :password] end
# @return [ URI ] The uri to the auhor page
@@ -32,11 +33,15 @@ class WpUser < WpItem
end
# @param [ WpUser ] other
#
# @return [ Boolean ]
def ==(other)
self === other
end
# @param [ WpUser ] other
#
# @return [ Boolean ]
def ===(other)
id === other.id && login === other.login
end