Skip to content

Instantly share code, notes, and snippets.

View AnuchitO's full-sized avatar

Anuchit Prasertsang AnuchitO

View GitHub Profile
*** Test Cases ***
Large JSON On Robot Framework
${profile}= Catenate SEPARATOR=
... {
... "name" : "Anuchit",
... "last_name" : "Prasertsnag",
... "description" : "robot framework large json",
... "version_control" : "git",
... "url" : "https://github.com/AnuchitPrasertsang"
... }
*** Test Cases ***
Simple JSON
Set Test Variable ${data} {"first_name":"Anuchit"}
Log ${data} console=True
package main
import "fmt"
type Profile struct {
Name string
}
type Handler func(*Profile)
@AnuchitO
AnuchitO / nagate_if_from.go
Last active August 29, 2015 14:22
Golang: Refactor Negate If Example,e
func (c *concealer) Seed() ([]byte,error){
if c.seed == nil {
c.seed,err = blockRandom.Generate(SeedSize)
if err != nil {
fmt.Println("Handler Error")
return nil,err
}
return c.seed,nil
}
return c.seed,nil

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@AnuchitO
AnuchitO / JSON Format API for Saving Supplier data
Last active August 29, 2015 14:14
ITMC-97 API for saving supplier data : JSON Format API for Saving Supplier data
{
"supplierCode": "TH1000",
"companyName": "sup_20f",
"defaultSupplierType": "RT",
"taxId": "tax_4de",
"username": "user_da7",
"defaultPaymentTerms": 30,
"vatSupplier": "Y",
"preferredDayForPo": "6",
"deliveryDay": "5",
public class Naming{
private String name;
}