cowprotocol / cowprotocol/dune-sync

Failing unit test

Open
#60 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
5
Forks
1
PR merge metrics
No merged PRs in 30d

Description

@fhenneke first pointed out that there is some test that is now failing. Since I am personally a bit ignorant about this, any help would be appreciated. One option would be to just remove this test. cc @bh2smith @MartinquaXD

`=================================== FAILURES ===================================
__________________________ TestIPFS.test_get_content ___________________________

self = <tests.unit.test_ipfs.TestIPFS testMethod=test_get_content>

def test_get_content(self):
    self.assertEqual(
        {
            "version": "0.1.0",
            "appCode": "CowSwap",
            "metadata": {
                "referrer": {
                    "version": "0.1.0",
                    "address": "0x424a46612794dbb8000194937834250Dc723fFa5",
                }
            },
        },
        Cid.old_schema(
            "3d876de8fcd70969349c92d731eeb0482fe8667ceca075592b8785081d630b9a"
        ).get_content(ACCESS_KEY, max_retries=10),
    )
       self.assertEqual(
        {
            "version": "1.0.0",
            "appCode": "CowSwap",
            "metadata": {
                "referrer": {
                    "kind": "referrer",
                    "referrer": "0x8c35B7eE520277D14af5F6098835A584C337311b",
                    "version": "1.0.0",
                }
            },
        },
        Cid.old_schema(
            "1FE7C5555B3F9C14FF7C60D90F15F1A5B11A0DA5B1E8AA043582A1B2E1058D0C"
        ).get_content(ACCESS_KEY),
    )
 AssertionError: {'version': '1.0.0', 'appCode': 'CowSwap'[122 chars]0'}}} != None

tests/unit/test_ipfs.py:73: AssertionError
=========================== short test summary info ============================
FAILED tests/unit/test_ipfs.py::TestIPFS::test_get_content - AssertionError: {'version': '1.0.0', 'appCode': 'CowSwap'[122 chars]0'}}} != None`

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running TestIPFS.test_get_content in tests/unit/test_ipfs.py and inspect the Cid.old_schema calls shown in the failure. Determine why the second call returns None, then make the test reflect the intended behavior or document why it should be removed; the targeted test should no longer fail.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend, testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.