Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

New tests do not get default value of custom field



We have a custom dropdown field.
It is set to mandatory, and one of the options is set as the default value.
The “Projects” option for the field is that it applies to all projects.

If I create a new test case (by clicking the “Add test case” link in the suite view, entering a test case title, then clicking the green tick) then this custom field seems to be “unset” rather than taking the default value.
]If I choose to view the custom field as a column in the test suite view, it has no value[/]
]If I click the test to view the test case; the field is missing on the page (not just the value - the heading for the field is also not showing). If I then Edit the test then the field appears and I can set it (but default dropdown value is blank rather than the set default)[/*]

As a workaround I can just consider “blank” to be equivalent to the default value in our automation scripts.

We have another custom field that appears to be set up identically that does not have this problem

Is this a known bug?



When I get a new test’s details via API (using Python) I get:

{ u'created_by': 20, u'created_on': 1395914890, u'custom_authored': None, u'custom_automation': 3, u'custom_description': None, u'custom_expected': None, u'custom_preconds': None, u'custom_test_steps': None, u'estimate': None, u'estimate_forecast': None, u'id': 8243, u'milestone_id': None, u'priority_id': 3, u'refs': None, u'section_id': 392, u'suite_id': 32, u'title': u'This test is just a test', u'type_id': 2, u'updated_by': 20, u'updated_on': 1395914890}

custom_authored is the affected field and is set to None (Python’s “null”)
custom_automation is another custom field with equivalent settings and it has its default value set fine



Thanks for your posting. If the dropdown field has a default value configured, then the inline “Add test case” feature should also use this value. It would be great if you could send us the custom field definitions to our help desk at so we can review your configuration. You can get this via the get_case_fields API method:



Thanks Tobias; I sent an email with the result of get_case_fields attached as a text file