While writing my first acceptance tests, I consist...
# help-connector-development
b
While writing my first acceptance tests, I consistently fail _validate_records_structure The error I am getting back speaks to columns existing in the data that does not exist in my json schema. Some example below:
Copy code
AssertionError:  Record namespace=None stream='mailbox_usage' data={'Report Refresh Date [...] emitted_at=1684509708046 from mailbox_usage stream with fields {'/Report Refresh Date' [...] should have some fields mentioned by json schema: {'/mailbox_usage/reportRefreshDate'
I originally thought that this was a formatting issue. I have since updated my implementation to reflect the format in my configured_catalog.
Copy code
{
    "streams": [
        {
            "stream": {
                "name": "mailbox_usage",
                "json_schema": {
                    "$schema": "<http://json-schema.org/draft-04/schema#>",
                    "type": "object",
                    "properties": {
                        "Report Refresh Date": {
                            "type": "string"
                        }
However, the problem persists. It is leaving me with two questions…. is the configured_catalog that I declared in my acceptance.py the schema that is being interrogated for this test? Secondly, am I missing a step to get pytest to pick up the new configurations? I’m noticing in my failure that it references another field that no longer exists in my project. Any assistance is appreciated
k
A message from kapa.ai
Hmm, I don't know enough to give you a confident answer yet. However, you can refer to the Airbyte documentation on [building a Python source](https://docs.airbyte.io/connector-development/connector-development-kit/python) and [connector development](https://docs.airbyte.io/connector-development) for more information and guidance on writing acceptance tests and configuring your catalog.
b
It looks like I must build my docker image for the pytest tests to pick up changes