Sat, 18 Nov 2017 13:07:26 +0100
Fixed some stupid bugs introduced by the last extension.
--- a/ChangeLog Sat Nov 18 12:40:04 2017 +0100 +++ b/ChangeLog Sat Nov 18 13:07:26 2017 +0100 @@ -1,5 +1,8 @@ ChangeLog --------- +Version 5.0.11: +- bug fix + Version 5.0.10: - added a dialog to enter data for running Django unit tests
--- a/PluginProjectDjango.py Sat Nov 18 12:40:04 2017 +0100 +++ b/PluginProjectDjango.py Sat Nov 18 13:07:26 2017 +0100 @@ -28,7 +28,7 @@ author = "Detlev Offenbach <detlev@die-offenbachs.de>" autoactivate = True deactivateable = True -version = "5.0.10" +version = "5.0.11" className = "ProjectDjangoPlugin" packageName = "ProjectDjango" shortDescription = "Project support for Django projects."
--- a/ProjectDjango/DjangoTestDataDialog.py Sat Nov 18 12:40:04 2017 +0100 +++ b/ProjectDjango/DjangoTestDataDialog.py Sat Nov 18 13:07:26 2017 +0100 @@ -56,23 +56,23 @@ (list of str, str, list of str, list of str, bool, bool) """ labelsStr = self.labelsComboBox.currentText() + self.__project.setMostRecentTestData("RecentTestLabels", labelsStr) if labelsStr: - self.__project.setMostRecentTestData("RecentTestLabels", labelsStr) labels = labelsStr.split() else: labels = [] - tagsStr = self.labelsComboBox.currentText() + tagsStr = self.tagsComboBox.currentText() + self.__project.setMostRecentTestData("RecentTestTags", tagsStr) if tagsStr: - self.__project.setMostRecentTestData("RecentTestTags", tagsStr) tags = tagsStr.split() else: tags = [] - excludeTagsStr = self.labelsComboBox.currentText() + excludeTagsStr = self.excludeTagsComboBox.currentText() + self.__project.setMostRecentTestData("RecentTestExcludeTags", + excludeTagsStr) if excludeTagsStr: - self.__project.setMostRecentTestData("RecentTestExcludeTags", - excludeTagsStr) excludeTags = excludeTagsStr.split() else: excludeTags = []
--- a/ProjectDjango/Project.py Sat Nov 18 12:40:04 2017 +0100 +++ b/ProjectDjango/Project.py Sat Nov 18 13:07:26 2017 +0100 @@ -97,9 +97,6 @@ Class implementing the Django project support. """ RecentApplicationsKey = "Django/RecentApplications" -## RecentTestLabelsKey = "Django/RecentTestLabels" -## RecentTestTagsKey = "Django/RecentTestTags" -## RecentTestExcludeTagsKey = "Django/RecentTestExcludeTags" def __init__(self, plugin, parent=None): """ @@ -2763,35 +2760,32 @@ labels, pattern, tags, excludeTags, keep, reverse = \ dlg.getData() - args = Utilities.parseOptionString(consoleCmd) - args[0] = Utilities.getExecutablePath(args[0]) - args.append(self.__getPythonExecutable()) - if deprecation: - args.append("-Wall") - args.append("manage.py") - args.append("test") - if pattern: - args.append("--pattern") - args.append(pattern) - for tag in tags: - args.append("--tag") - args.append(tag) - for tag in excludeTags: - args.append("--exclude-tag") - args.append(tag) - if keep: - args.append("--keepdb") - if reverse: - args.append("--reverse") - args.extend(labels) - - self.__adjustWorkingDirectory(args, wd) - started, pid = QProcess.startDetached(args[0], args[1:], wd) - if not started: - E5MessageBox.critical( - None, - self.tr('Process Generation Error'), - self.tr('The Django process could not be started.')) + args = Utilities.parseOptionString(consoleCmd) + args[0] = Utilities.getExecutablePath(args[0]) + args.append(self.__getPythonExecutable()) + if deprecation: + args.append("-Wall") + args.append("manage.py") + args.append("test") + if pattern: + args.append("--pattern=" + pattern) + for tag in tags: + args.append("--tag=" + tag) + for tag in excludeTags: + args.append("--exclude-tag=" + tag) + if keep: + args.append("--keepdb") + if reverse: + args.append("--reverse") + args.extend(labels) + + self.__adjustWorkingDirectory(args, wd) + started, pid = QProcess.startDetached(args[0], args[1:], wd) + if not started: + E5MessageBox.critical( + None, + self.tr('Process Generation Error'), + self.tr('The Django process could not be started.')) def __runTestServer(self): """