mirror of
https://github.com/YunoHost/package_linter.git
synced 2024-09-03 20:06:12 +02:00
Add info about osbsolete/superflous ask strings
This commit is contained in:
parent
0b1aa10e44
commit
975e2de5fc
1 changed files with 11 additions and 0 deletions
|
@ -1089,6 +1089,17 @@ class Manifest(TestSuite):
|
||||||
"No need to specify the choices list yourself." % argument["name"]
|
"No need to specify the choices list yourself." % argument["name"]
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@test()
|
||||||
|
def obsolete_ask_strings(self):
|
||||||
|
|
||||||
|
ask_string_managed_by_the_core = [("domain", "domain"), ("path", "path"), ("admin", "user"), ("is_public", "boolean"), ("password", "password")]
|
||||||
|
|
||||||
|
for argument in self.manifest["arguments"].get("install", []):
|
||||||
|
|
||||||
|
if argument.get("ask") and (argument.get("name"), argument.get("type")) in ask_string_managed_by_the_core:
|
||||||
|
yield Info("Ask string for argument %s is superflous / will be ignored. Since 4.1, the core handles the ask string for some reccuring arg name/type for consistency and easier i18n. See https://github.com/YunoHost/example_ynh/pull/142" % argument.get("name"))
|
||||||
|
|
||||||
|
|
||||||
@test()
|
@test()
|
||||||
def is_public_help(self):
|
def is_public_help(self):
|
||||||
for argument in self.manifest["arguments"].get("install", []):
|
for argument in self.manifest["arguments"].get("install", []):
|
||||||
|
|
Loading…
Reference in a new issue