Skip to content

Instantly share code, notes, and snippets.

View thiagobutignon's full-sized avatar

Thiago Butignon Claramunt thiagobutignon

  • 19:34 (UTC -03:00)
View GitHub Profile
/**
* This file is part of the Softbank Robotics tutorial project, specifically focused on animating
* the Pepper robot using the QiSDK framework. It demonstrates how to build and run animations
* alongside playing sound effects and handling robot lifecycle callbacks.
*
* @file AnimateTutorialActivity.kt
* @author Softbank Robotics Europe
* @since 2018
*/
import { HttpClient, HttpStatusCode } from '@/data/protocols'
import { InvalidCredentialError, UnexpectedError } from '@/domain/errors'

import { LoginUsecase } from '@/domain/usecases'

export class RemoteLogin implements LoginUsecase {
  constructor (
    private readonly url: string,
 private readonly httpClient: HttpClient
import { HttpClient, HttpStatusCode } from '@/data/protocols'
import { InvalidCredentialError, UnexpectedError } from '@/domain/errors'

import { LoginUsecase } from '@/domain/usecases'

export class RemoteLogin implements LoginUsecase {
  constructor (
    private readonly url: string,
 private readonly httpClient: HttpClient
{
"name": "Thiago",
"email": "[email protected]"
}
@thiagobutignon
thiagobutignon / boxed-text.json
Last active September 17, 2021 03:57
Zup Innovation - Thiago Butignon Claramunt
{
"_beagleComponent_": "beagle:container",
"style": {
"backgroundColor": "#FF0000",
"padding": {
"all": {
"value": 60,
"type": "REAL"
}
}
@thiagobutignon
thiagobutignon / AuthorizationDecorator.swift
Last active September 17, 2020 20:47
AuthorizationDecorator
class AuthorizationDecorator: HttpClient {
private let httpClient: HttpClient
public init(httpClient: HttpClient) {
self.httpClient = httpClient
}
public func request(data: HttpRequest, completion: @escaping (Result<Data?, HttpError>) -> Void) {
let getToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MSwiaWF0IjoxNjAwMzczNTczLCJleHAiOjE2MDA0NTk5NzN9.kKCRLckJdCaSMks6WBDX52wIAB92E8wTnHgPix3PxW4"
data.headers!["Authorization"] = "Bearer \(getToken)"
import faker from 'faker'
import { AddAccount } from '@/domain/usecases'
import { mockAccountResultModel } from '@/domain/test'
export const mockAddAccountParams = (): AddAccount.Params => {
const password = faker.internet.password()
return {
fullName: faker.name.findName(),
username: faker.internet.userName(),
email: faker.internet.email(),
import React from 'react'
import { Router } from 'react-router-dom'
import { createMemoryHistory } from 'history'
import faker from 'faker'
import {
render,
RenderResult,
fireEvent,
cleanup,
waitFor
import Foundation
struct Character: Model {
let id: Int
let name, resultDescription: String
let modified: Date
let thumbnail: Image
let resourceURI: String
let comics, series: ComicsList
let stories: StoryList
{touched.zipcode && !errors.zipcode
? setTimeout(() => {
cep(values.zipcode)
.then(response => {
setFieldTouched('zipcode', false);
console.log(response);
setFieldValue('street', response.street);
setFieldValue('city', response.city);
setFieldValue('state', response.state);
setFieldValue('neighborhood', response.neighborhood);