Did I find the right examples for you? yes no

All Samples(3)  |  Call(3)  |  Derive(0)  |  Import(0)

src/c/a/candideitorg-django-0.0.1/candidator/elections/views/medianaranja_views.py   candideitorg-django(Download)
        visitor_score = VisitorScore.objects.create(visitor=visitor, candidate_name=candidate.name,score=global_score)
        for i,category_score in enumerate(category_scores):
            categoryscore = CategoryScore.objects.create(visitor_score=visitor_score,category_score=category_score, category_name=categories[i])
 
        scores_and_candidates.append([global_score,category_scores,candidate])

src/c/a/candideitorg-django-0.0.1/candidator/elections/tests/medianaranja.py   candideitorg-django(Download)
        visitor1 = Visitor.objects.create(election = self.election, election_url = reverse("election_detail",kwargs={'username': 'joe', 'slug':'barbaz'}))
        visitor_score = VisitorScore.objects.create(visitor=visitor1,candidate_name=self.candidate1.name,score=get_score1[0])
        category_score1 = CategoryScore.objects.create(visitor_score=visitor_score,category_score=get_score1[1][0],category_name=categories[0])
        category_score2 = CategoryScore.objects.create(visitor_score=visitor_score,category_score=get_score1[1][1],category_name=categories[1])
        self.assertEqual(visitor_score.score, get_score1[0])