loklak / loklak_python_api

The loklak API for Python which makes it very easy to use and as a strict replacement to the twitter API
1.09k stars 26 forks source link

Add aggregations test #20

Closed PolBaladas closed 8 years ago

PolBaladas commented 8 years ago

Added aggregations method test. Checks the status code of the response.

landscape-bot commented 8 years ago

Code Health Code quality remained the same when pulling 936c968 on PolBaladas:master into 834009c on loklak:master.

PolBaladas commented 8 years ago

Yeah, i coded that but the aggregations method just returns the ok 200 status, it doesn't return json data so i can't check if it contains all that stuff. Do you have any idea about what's happening?

landscape-bot commented 8 years ago

Code Health Code quality remained the same when pulling 79a0339 on PolBaladas:master into 834009c on loklak:master.

landscape-bot commented 8 years ago

Code Health Code quality remained the same when pulling 06e7bfd on PolBaladas:master into 834009c on loklak:master.

PolBaladas commented 8 years ago

Aggregations test check for tag :+1: I'll start working on the get_map test.

PolBaladas commented 8 years ago

What do you think about this solution to test the get_map method?

def test_get_map(self):
        """test get the map"""
        result = self.loklak.get_map(17.582729, 79.118320, 512, 512, 12, 'Hello')
        self.assertTrue(result[:8] == '\211PNG\r\n\032\n'and (result[12:16] == 'IHDR'))

Thanks

landscape-bot commented 8 years ago

Code Health Code quality remained the same when pulling ff33145 on PolBaladas:master into 834009c on loklak:master.

landscape-bot commented 8 years ago

Code Health Code quality remained the same when pulling 5d5bc29 on PolBaladas:master into 834009c on loklak:master.

sudheesh001 commented 8 years ago

Please squash all this into one single commit and we're good to go !

PolBaladas commented 8 years ago

Hi sudheesh, i can't squash into a single commit since i didn't create a new branch on my cloned repo. I have all changes on master. What can i do? Thanks

sudheesh001 commented 8 years ago

Always work on a new branch when you're working on patches. As of now what you can do is you can reset the repository to a stable git history and pull all the changes from the main repo, then redo this work.

git reset --hard 7486bbfc911eacf86aaa43bf2d97b25da80eb9d4
git pull https://github.com/loklak/python-loklak-api master
git checkout -b PatchName

Do the required changes, then push back to your repo and send a pull request !

PolBaladas commented 8 years ago

should work now Thanks