diff options
author | Rico Tzschichholz <ricotz@ubuntu.com> | 2017-05-01 22:06:39 +0200 |
---|---|---|
committer | Rico Tzschichholz <ricotz@ubuntu.com> | 2017-11-19 12:35:04 +0100 |
commit | 9c3f7fab780a9b7e389acb48c54cf321fca565b3 (patch) | |
tree | 331b0a5499c35c07e8c988e0306c6c1fc4406f97 | |
parent | 627fa24967309ab022a77d27daa85edb16b30dbe (diff) | |
download | vala-9c3f7fab780a9b7e389acb48c54cf321fca565b3.tar.gz |
Minor API cleaning
-rw-r--r-- | valadate/testconfig.vala | 18 | ||||
-rw-r--r-- | valadate/testreportprinter.vala | 2 | ||||
-rw-r--r-- | valadate/xmltestreportprinter.vala | 1 |
3 files changed, 10 insertions, 11 deletions
diff --git a/valadate/testconfig.vala b/valadate/testconfig.vala index d6dcadcea..22da8d6a2 100644 --- a/valadate/testconfig.vala +++ b/valadate/testconfig.vala @@ -45,7 +45,7 @@ public class Valadate.TestConfig { private static bool _version; private static string _path = null; - public const OptionEntry[] options = { + private const OptionEntry[] options = { { "format", 'f', 0, OptionArg.STRING, ref _format, "Output test results using format", "FORMAT" }, { "", 'k', 0, OptionArg.NONE, ref _keepgoing, "Skip failed tests and continue running", null }, { "list", 'l', 0, OptionArg.NONE, ref _list, "List test cases available in a test executable", null }, @@ -57,15 +57,13 @@ public class Valadate.TestConfig { { null } }; - public OptionContext opt_context; - - public virtual string format { + public string format { get { return _format; } } - public virtual string seed { + public string seed { get { return _seed; } @@ -89,30 +87,32 @@ public class Valadate.TestConfig { } } - public virtual bool list_only { + public bool list_only { get { return _list; } } - public virtual bool keep_going { + public bool keep_going { get { return _keepgoing; } } - public virtual int timeout { + public int timeout { get { return _timeout; } } - public virtual bool timed { + public bool timed { get { return _timed; } } + private OptionContext opt_context; + public TestConfig (string[] args) { _running_test = null; diff --git a/valadate/testreportprinter.vala b/valadate/testreportprinter.vala index da58a95db..8e0b399bd 100644 --- a/valadate/testreportprinter.vala +++ b/valadate/testreportprinter.vala @@ -36,7 +36,7 @@ public abstract class Valadate.TestReportPrinter { } } - public TestConfig config {get; set;} + public TestConfig config { get; private set; } internal TestReportPrinter (TestConfig config) throws Error { this.config = config; diff --git a/valadate/xmltestreportprinter.vala b/valadate/xmltestreportprinter.vala index 9a023c9c9..bdb634cfa 100644 --- a/valadate/xmltestreportprinter.vala +++ b/valadate/xmltestreportprinter.vala @@ -37,7 +37,6 @@ internal class Valadate.XmlTestReportPrinter : TestReportPrinter { public XmlTestReportPrinter (TestConfig config) throws Error { base (config); - this.config = config; xml = new XmlFile.from_string (XML_DECL + TESTSUITES_XML); } |