Bug 34550 - Test CLI tool import_computer
Test CLI tool import_computer
Status: CLOSED FIXED
Product: UCS@school
Classification: Unclassified
Component: ucs-test
UCS@school 3.2 R2
Other Linux
: P5 normal (vote)
: UCS@school 3.2 R2 Errata
Assigned To: Sönke Schwardt-Krummrich
Florian Best
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-04-15 10:04 CEST by Sönke Schwardt-Krummrich
Modified: 2014-08-27 17:01 CEST (History)
0 users

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sönke Schwardt-Krummrich univentionstaff 2014-04-15 10:04:37 CEST
For refactoring the CLI tool "import_computer" all functions should be tested via ucs-test. Currently the tool uses it's own implementation (which shall be used as reference!).

The upcoming UCS@school import library will provide the same functionality as the import CLI tools and will be used within the CLI tools in near future.

Ideally the test script is able to test the CLI tool as well as the import lib.
Comment 1 Stefan Gohmann univentionstaff 2014-05-10 21:04:14 CEST
CLI tests have been added: r50116

The python import has to be added in essential/importcomputers.py: _run_import_via_python_api
Comment 2 Stefan Gohmann univentionstaff 2014-05-12 07:20:48 CEST
Some cleanup: rr50117 + r50125
Comment 3 Florian Best univentionstaff 2014-08-20 09:30:29 CEST
set_zone_verwaltung() and set_zone_edukativ() is called for computer types which aren't memberserver → will not work.

 71 »   def set_zone_edukativ(self):
 72 »   »   if self.ctype == 'memberserver':
 73 »   »   »   self.zone = 'edukativ'
Comment 4 Sönke Schwardt-Krummrich univentionstaff 2014-08-21 16:14:12 CEST
Fixed a typo: set_zone_verwaltng() → set_zone_verwaltung()

(In reply to Florian Best from comment #3)
> set_zone_verwaltung() and set_zone_edukativ() is called for computer types
> which aren't memberserver → will not work.
> 
>  71 »   def set_zone_edukativ(self):
>  72 »   »   if self.ctype == 'memberserver':
>  73 »   »   »   self.zone = 'edukativ'

I think, this is ok. The ucs-school-python-lib currently does not support the import of memberserver. Therefore the memberserver tests are disabled within the test script. The zone attribute is currently only supported for memberservers
→ I think it's ok to leave it in its current state; if the behaviour of set_zone_edukativ() or set_zone_verwaltung() will change in future, the test will show if it's ok :-)
Comment 5 Florian Best univentionstaff 2014-08-22 09:09:41 CEST
OK
Comment 6 Sönke Schwardt-Krummrich univentionstaff 2014-08-27 17:01:48 CEST
UCS@school 3.2 R2 v2 has been released:
http://docs.univention.de/release-notes-ucsschool-3.2R2v2-de.html

If this error occurs again, please use "Clone This Bug".