Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing Question #3

Closed
blsmit5728 opened this issue Feb 26, 2014 · 5 comments
Closed

Testing Question #3

blsmit5728 opened this issue Feb 26, 2014 · 5 comments

Comments

@blsmit5728
Copy link

I have been working on adding more to your API and was trying to figure out the whole testing method you have implemented. I tried adding a method for user/list to the tests but it kept failing the json parsing (I added a list.json under responses/user/ folder). I'd like to contribute to making this API more robust, but I don't want to issue a pull request until I can run the same unit tests you have implemented. Thanks.
PS: didn;t know how to contact you, figured this was the easiest.

@z4r
Copy link
Owner

z4r commented Feb 26, 2014

Hi @blsmit5728,
thx for your interest.
I suggest you to commit something on your fork so i could understand what you're misunderstanding. :)

Anyway you can contact me on skype: z4erre

cu

@blsmit5728
Copy link
Author

There should be a couple commits there from today on my fork. No skype, sorry

@z4r
Copy link
Owner

z4r commented Feb 27, 2014

trakt/api.py

class User(AbstractApi):
    @classmethod
    def list(cls, user, slug):
        """
        returns the Users list that was requested
        """
        return cls._get('user/list', user, slug)

    @classmethod
    def lists(cls, user):
        """
        returns the availble lists for a user
        """
        return cls._get('user/lists', user)

    @classmethod
    def profile(cls, user):
        return cls._get('user/profile', user)

    @classmethod
    def progress_collected(cls, user):
        return cls._get('user/progress/collected', user)

trakt/tests/test_api.py

response = User.list(user='justin', slug='Example')

and a missing comma in trakt/tests/response/user/list.json around line 88

@z4r
Copy link
Owner

z4r commented Sep 18, 2014

If you need any help re open this issue

@z4r z4r closed this as completed Sep 18, 2014
@blsmit5728
Copy link
Author

I think I'm good, i have a few changes if you'd like me to up stream them I
can. I never got around to writing all the tests though.

Sent from my iPhone

On Sep 18, 2014, at 02:07, Andrea de Marco notifications@github.com wrote:

If you need any help re open this issue


Reply to this email directly or view it on GitHub
#3 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants