| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 617a025 commit cf0049b
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -102,7 +102,7 @@ class ProjectLabel( | |||
| 102 | 102 | PromoteMixin, SubscribableMixin, SaveMixin, ObjectDeleteMixin, RESTObject | |
| 103 | 103 | ): | |
| 104 | 104 | _id_attr = "name" | |
| 105 | - manager: "ProjectLabelManager" | ||
| 105 | + # manager: "ProjectLabelManager" | ||
| 106 | 106 | ||
| 107 | 107 | # Update without ID, but we need an ID to get from list. | |
| 108 | 108 | @exc.on_http_error(exc.GitlabUpdateError) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -140,13 +140,21 @@ def test_project_housekeeping(project): | |||
| 140 | 140 | ||
| 141 | 141 | ||
| 142 | 142 | def test_project_labels(project): | |
| 143 | + print("JLV: project.id:", project.id) | ||
| 144 | + print("JLV: project.labels:", project.labels) | ||
| 143 | 145 | label = project.labels.create({"name": "label", "color": "#778899"}) | |
| 146 | + print("JLV: type(label):", type(label)) | ||
| 147 | + print("JLV: label.manager._computed_path:", label.manager._computed_path) | ||
| 148 | + print("JLV: label.manager._parent:", label.manager._parent) | ||
| 144 | 149 | labels = project.labels.list() | |
| 145 | 150 | assert len(labels) == 1 | |
| 146 | 151 | ||
| 147 | 152 | label = project.labels.get("label") | |
| 148 | 153 | assert label == labels[0] | |
| 149 | 154 | ||
| 155 | + print("JLV: type(label):", type(label)) | ||
| 156 | + print("JLV: label.manager._computed_path:", label.manager._computed_path) | ||
| 157 | + print("JLV: label.manager._parent:", label.manager._parent) | ||
| 150 | 158 | label.new_name = "labelupdated" | |
| 151 | 159 | label.save() | |
| 152 | 160 | assert label.name == "labelupdated" | |
@@ -160,6 +168,8 @@ def test_project_labels(project): | |||
| 160 | 168 | label.delete() | |
| 161 | 169 | assert len(project.labels.list()) == 0 | |
| 162 | 170 | ||
| 171 | + assert "1" is None | ||
| 172 | + | ||
| 163 | 173 | ||
| 164 | 174 | def test_project_label_promotion(gl, group): | |
| 165 | 175 | """ | |
| Back | FazBrowse Home | New Git URL |
0 commit comments