diff --git a/server/static/css/neat.css b/assets/static/css/neat.css similarity index 100% rename from server/static/css/neat.css rename to assets/static/css/neat.css diff --git a/server/templates/exam.tpl b/assets/templates/exam.tpl similarity index 100% rename from server/templates/exam.tpl rename to assets/templates/exam.tpl diff --git a/cli/.gitignore b/cli/.gitignore deleted file mode 100644 index 2de4cc4..0000000 --- a/cli/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -cli -testdata -*.bk diff --git a/cli/main.go b/cli/main.go deleted file mode 100644 index c1bfe44..0000000 --- a/cli/main.go +++ /dev/null @@ -1,144 +0,0 @@ -package main - -import ( - "fmt" - "log" - "os" - - "git.andreafazzi.eu/andrea/probo/sessionmanager" - "git.andreafazzi.eu/andrea/probo/store/file" - "github.com/urfave/cli/v2" -) - -func main() { - file.DefaultBaseDir = "testdata" - - sStore, err := file.NewDefaultSessionFileStore() - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - pStore, err := file.NewParticipantDefaultFileStore() - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - qStore, err := file.NewDefaultQuizFileStore() - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - sm, err := sessionmanager.NewSessionManager( - "http://localhost:8080/", - pStore.Storer, - qStore.Storer, - nil, - nil, - ) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - app := &cli.App{ - Name: "probo-cli", - Usage: "Quiz Management System for Hackers!", - Commands: []*cli.Command{ - { - Name: "init", - Aliases: []string{"i"}, - Usage: "Initialize the current directory", - Action: func(cCtx *cli.Context) error { - return nil - }, - }, - { - Name: "session", - Aliases: []string{"s"}, - Usage: "options for command 'session'", - Subcommands: []*cli.Command{ - { - Name: "create", - Usage: "Create a new exam session", - Action: func(cCtx *cli.Context) error { - if cCtx.Args().Len() < 1 { - log.Fatalf("Please provide a session name as first argument of create.") - } - - session, err := sm.Push(cCtx.Args().First()) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - _, err = sStore.Create(session) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - log.Println("Session upload completed with success!") - - for _, p := range pStore.ReadAll() { - log.Printf("http://localhost:8080/%v/%v", session.ID, p.Token) - } - - return nil - - }, - }, - { - Name: "pull", - Usage: "Download responses from a session", - Action: func(cCtx *cli.Context) error { - if cCtx.Args().Len() < 1 { - log.Fatalf("Please provide a session ID as first argument of pull.") - } - - rStore, err := file.NewDefaultResponseFileStore() - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - err = sm.Pull(rStore, cCtx.Args().First()) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - log.Println("Responses download completed with success!") - - return nil - - }, - }, - { - Name: "scores", - Usage: "Show the scores for the given session", - Action: func(cCtx *cli.Context) error { - if cCtx.Args().Len() < 1 { - log.Fatalf("Please provide a session name as first argument of 'score'.") - } - session, err := sStore.Read(cCtx.Args().First()) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - rStore, err := file.NewDefaultResponseFileStore() - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - scores, err := sessionmanager.NewScores(rStore, session) - if err != nil { - log.Fatalf("An error occurred: %v", err) - } - - fmt.Println(scores) - - return nil - - }, - }, - }, - }, - }, - } - - if err := app.Run(os.Args); err != nil { - log.Fatal(err) - } -} diff --git a/client/client.go b/client/client.go deleted file mode 100644 index ea1c4ff..0000000 --- a/client/client.go +++ /dev/null @@ -1,106 +0,0 @@ -package client - -import "git.andreafazzi.eu/andrea/probo/models" - -type Question struct { - Text string `json:"text"` -} - -type Answer struct { - Text string `json:"text"` - Correct bool `json:"correct"` -} - -type Quiz struct { - Question *Question `json:"question"` - Answers []*Answer `json:"answers"` -} - -type Collection struct { - Name string `json:"name"` - Query string `json:"query"` -} - -type Participant struct { - Firstname string `json:"firstname"` - Lastname string `json:"lastname"` - Token uint `json:"token"` - Attributes map[string]string `json:"attributes"` -} - -type Exam struct { - Name string `json:"name"` - Description string `json:"description"` - - ParticipantID string `json:"participant_id"` - CollectionID string `json:"collection_id"` -} - -type BaseResponse struct { - Status string `json:"status"` - Message string `json:"message"` -} - -type ReadAllQuizResponse struct { - BaseResponse - Content []*models.Quiz `json:"content"` -} - -type CreateQuizResponse struct { - BaseResponse - Content *models.Quiz `json:"content"` -} - -type UpdateQuizResponse struct { - BaseResponse - Content *models.Quiz `json:"content"` -} - -type CreateQuestionRequest struct { - *Question -} - -type CreateAnswerRequest struct { - *Answer -} - -type CreateUpdateQuizRequest struct { - *Quiz - *models.Meta -} - -type DeleteQuizRequest struct { - ID string -} - -type CreateUpdateCollectionRequest struct { - *Collection -} - -type DeleteCollectionRequest struct { - ID string -} - -type CreateUpdateExamRequest struct { - *Exam -} - -type DeleteExamRequest struct { - ID string -} - -type ReadExamByIDRequest struct { - ID string -} - -type CreateUpdateParticipantRequest struct { - *Participant -} - -type DeleteParticipantRequest struct { - ID string -} - -type ReadParticipantByIDRequest struct { - ID string -} diff --git a/cmd/probo-cli/main.go b/cmd/probo-cli/main.go new file mode 100644 index 0000000..2aa0b43 --- /dev/null +++ b/cmd/probo-cli/main.go @@ -0,0 +1,60 @@ +package main + +import ( + "log" + "log/slog" + "os" + + "git.andreafazzi.eu/andrea/probo/lib/store/file" + "github.com/urfave/cli/v2" +) + +func main() { + _, err := os.Stat(file.DefaultBaseDir) + if err != nil { + slog.Info("Base directory not found. Create the folder structure...") + for _, dir := range file.Dirs { + err := os.MkdirAll(dir, os.ModePerm) + if err != nil { + log.Fatal(err) + } + slog.Info("Create", "directory", dir) + } + + slog.Info("Folder structure created without issues.") + os.Exit(0) + } + + app := &cli.App{ + Name: "probo-cli", + Usage: "Quiz Management System for Hackers!", + Commands: []*cli.Command{ + { + Name: "session", + Aliases: []string{"s"}, + Usage: "options for command 'session'", + Subcommands: []*cli.Command{ + { + Name: "push", + Usage: "Create a new exam session", + Action: push, + }, + { + Name: "pull", + Usage: "Download responses from a session", + Action: pull, + }, + { + Name: "scores", + Usage: "Show the scores for the given session", + Action: scores, + }, + }, + }, + }, + } + + if err := app.Run(os.Args); err != nil { + log.Fatal(err) + } +} diff --git a/cmd/probo-cli/session.go b/cmd/probo-cli/session.go new file mode 100644 index 0000000..e14c53e --- /dev/null +++ b/cmd/probo-cli/session.go @@ -0,0 +1,198 @@ +package main + +import ( + "fmt" + "log" + + "git.andreafazzi.eu/andrea/probo/lib/sessionmanager" + "git.andreafazzi.eu/andrea/probo/lib/store/file" + "github.com/charmbracelet/bubbles/textinput" + tea "github.com/charmbracelet/bubbletea" + "github.com/urfave/cli/v2" +) + +type model struct { + textInput textinput.Model + err error +} + +type ( + errMsg error +) + +func initialModel() *model { + ti := textinput.New() + ti.Placeholder = "My exam session" + ti.Focus() + ti.CharLimit = 156 + ti.Width = 20 + + return &model{ + textInput: ti, + err: nil, + } +} + +func (m *model) Init() tea.Cmd { + return textinput.Blink +} + +func (m *model) Update(msg tea.Msg) (tea.Model, tea.Cmd) { + var cmd tea.Cmd + + switch msg := msg.(type) { + case tea.KeyMsg: + switch msg.Type { + case tea.KeyEnter, tea.KeyCtrlC, tea.KeyEsc: + return m, tea.Quit + } + + // We handle errors just like any other message + case errMsg: + m.err = msg + return m, nil + } + + m.textInput, cmd = m.textInput.Update(msg) + return m, cmd +} + +func (m *model) View() string { + return fmt.Sprintf( + "\nPlease insert the name of the session\n\n%s\n\n%s", + m.textInput.View(), + "(esc to quit)", + ) + "\n" +} + +func push(cCtx *cli.Context) error { + pStore, err := file.NewParticipantDefaultFileStore() + if err != nil { + return cli.Exit(fmt.Sprintf("An error occurred: %v", err), 1) + } + + participants := pStore.ReadAll() + + if len(participants) == 0 { + return cli.Exit("No participants found!", 1) + } + + sessionName := cCtx.Args().First() + + if cCtx.Args().Len() < 1 { + m := initialModel() + p := tea.NewProgram(m) + if _, err := p.Run(); err != nil { + log.Fatal(err) + } + sessionName = m.textInput.Value() + } + + sStore, err := file.NewDefaultSessionFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + qStore, err := file.NewDefaultQuizFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + sm, err := sessionmanager.NewSessionManager( + "http://localhost:8080/", + pStore.Storer, + qStore.Storer, + nil, + nil, + ) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + session, err := sm.Push(sessionName) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + _, err = sStore.Create(session) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + log.Println("Session upload completed with success!") + + for _, p := range pStore.ReadAll() { + log.Printf("http://localhost:8080/%v/%v", session.ID, p.Token) + } + + return nil + +} + +func pull(cCtx *cli.Context) error { + if cCtx.Args().Len() < 1 { + log.Fatalf("Please provide a session ID as first argument of pull.") + } + + rStore, err := file.NewDefaultResponseFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + pStore, err := file.NewParticipantDefaultFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + qStore, err := file.NewDefaultQuizFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + sm, err := sessionmanager.NewSessionManager( + "http://localhost:8080/", + pStore.Storer, + qStore.Storer, + nil, + nil, + ) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + err = sm.Pull(rStore, cCtx.Args().First()) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + log.Println("Responses download completed with success!") + + return nil +} + +func scores(cCtx *cli.Context) error { + if cCtx.Args().Len() < 1 { + log.Fatalf("Please provide a session name as first argument of 'score'.") + } + + sStore, err := file.NewDefaultSessionFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + session, err := sStore.Read(cCtx.Args().First()) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + rStore, err := file.NewDefaultResponseFileStore() + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + scores, err := sessionmanager.NewScores(rStore, session) + if err != nil { + log.Fatalf("An error occurred: %v", err) + } + + fmt.Println(scores) + + return nil +} diff --git a/cmd/probo-cli/testdata.bk/exams/exam_0249a3d3-d62c-469f-916a-22ef2210df01.json b/cmd/probo-cli/testdata.bk/exams/exam_0249a3d3-d62c-469f-916a-22ef2210df01.json new file mode 100644 index 0000000..741a8be --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_0249a3d3-d62c-469f-916a-22ef2210df01.json @@ -0,0 +1 @@ +{"id":"0249a3d3-d62c-469f-916a-22ef2210df01","created_at":"2023-12-14T17:05:57.284916041+01:00","updated_at":"2023-12-14T17:45:08.905072153+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:05:57.276521018+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:05:57.276792157+01:00","hash":"","question":{"id":"4d83355e-6bd3-4c63-be23-3115debe5462","created_at":"2023-12-14T17:05:57.276769264+01:00","updated_at":"2023-12-14T17:05:57.276769398+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:05:57.276838779+01:00","hash":"","question":{"id":"d0561675-0643-498b-b495-7ea351aeb027","created_at":"2023-12-14T17:05:57.276828009+01:00","updated_at":"2023-12-14T17:05:57.276828098+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:05:57.27688532+01:00","hash":"","question":{"id":"12727ba0-9ccc-430e-9919-fbacb7f032d2","created_at":"2023-12-14T17:05:57.276869592+01:00","updated_at":"2023-12-14T17:05:57.276869653+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_0ad742cd-80f4-4905-8ddb-66b5fa2dba51.json b/cmd/probo-cli/testdata.bk/exams/exam_0ad742cd-80f4-4905-8ddb-66b5fa2dba51.json new file mode 100644 index 0000000..d2e76ee --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_0ad742cd-80f4-4905-8ddb-66b5fa2dba51.json @@ -0,0 +1 @@ +{"id":"0ad742cd-80f4-4905-8ddb-66b5fa2dba51","created_at":"2023-12-14T17:43:18.127221296+01:00","updated_at":"2023-12-14T17:45:08.905232491+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:43:18.10506937+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:43:18.105224643+01:00","hash":"","question":{"id":"9aadd35f-b345-42b7-8d6d-627f279a16d9","created_at":"2023-12-14T17:43:18.105199556+01:00","updated_at":"2023-12-14T17:43:18.105199698+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:43:18.10527206+01:00","hash":"","question":{"id":"9531429d-dd38-4d21-820b-bf2ba1177a91","created_at":"2023-12-14T17:43:18.105261438+01:00","updated_at":"2023-12-14T17:43:18.105261513+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:43:18.105321478+01:00","hash":"","question":{"id":"afdee6d2-5dae-445f-91e6-4fe71f163032","created_at":"2023-12-14T17:43:18.105306543+01:00","updated_at":"2023-12-14T17:43:18.105306605+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_196b6928-079f-41d2-bb98-cbf0a243e1bc.json b/cmd/probo-cli/testdata.bk/exams/exam_196b6928-079f-41d2-bb98-cbf0a243e1bc.json new file mode 100644 index 0000000..654aa80 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_196b6928-079f-41d2-bb98-cbf0a243e1bc.json @@ -0,0 +1 @@ +{"id":"196b6928-079f-41d2-bb98-cbf0a243e1bc","created_at":"2023-12-14T17:01:05.115071983+01:00","updated_at":"2023-12-14T17:45:08.905373061+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:01:05.107657379+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:01:05.108222326+01:00","hash":"","question":{"id":"c20974ac-b6e5-4a14-8bc5-2556af7b3ca4","created_at":"2023-12-14T17:01:05.108206845+01:00","updated_at":"2023-12-14T17:01:05.10820691+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:01:05.107915761+01:00","hash":"","question":{"id":"13152027-08e7-4ea9-b055-8fa9b03b67e5","created_at":"2023-12-14T17:01:05.107895756+01:00","updated_at":"2023-12-14T17:01:05.107895888+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:01:05.107962826+01:00","hash":"","question":{"id":"9f9a5537-edbf-443f-b234-bd6d61293f4e","created_at":"2023-12-14T17:01:05.107951975+01:00","updated_at":"2023-12-14T17:01:05.107952042+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_1eb1ad71-3351-42ce-a7aa-64a8139310e5.json b/cmd/probo-cli/testdata.bk/exams/exam_1eb1ad71-3351-42ce-a7aa-64a8139310e5.json new file mode 100644 index 0000000..f3d86f5 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_1eb1ad71-3351-42ce-a7aa-64a8139310e5.json @@ -0,0 +1 @@ +{"id":"1eb1ad71-3351-42ce-a7aa-64a8139310e5","created_at":"2023-12-14T17:06:10.084641277+01:00","updated_at":"2023-12-14T17:45:08.90550321+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:06:10.076208183+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:06:10.07637237+01:00","hash":"","question":{"id":"51c07172-2ed8-4677-bb6f-d881714ded9b","created_at":"2023-12-14T17:06:10.076351886+01:00","updated_at":"2023-12-14T17:06:10.076352015+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:06:10.076421327+01:00","hash":"","question":{"id":"2204fa34-4c3d-4348-9f13-dad2cc89e0bf","created_at":"2023-12-14T17:06:10.076410271+01:00","updated_at":"2023-12-14T17:06:10.076410369+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:06:10.076682973+01:00","hash":"","question":{"id":"99e9fcd9-4acc-4ff4-9f92-09df8ebe4559","created_at":"2023-12-14T17:06:10.076667178+01:00","updated_at":"2023-12-14T17:06:10.076667256+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_214f5576-fbe2-42ec-be78-65649c422534.json b/cmd/probo-cli/testdata.bk/exams/exam_214f5576-fbe2-42ec-be78-65649c422534.json new file mode 100644 index 0000000..9180e51 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_214f5576-fbe2-42ec-be78-65649c422534.json @@ -0,0 +1 @@ +{"id":"214f5576-fbe2-42ec-be78-65649c422534","created_at":"2023-12-14T15:20:59.210075623+01:00","updated_at":"2023-12-14T17:45:08.90563059+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T15:20:59.208883999+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T15:20:59.209046632+01:00","hash":"","question":{"id":"6c609489-7891-40c2-a3d3-7c9c164034cb","created_at":"2023-12-14T15:20:59.209026727+01:00","updated_at":"2023-12-14T15:20:59.209026868+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T15:20:59.209095264+01:00","hash":"","question":{"id":"5013c0b9-091e-4c80-be38-967a1a0860a7","created_at":"2023-12-14T15:20:59.209084369+01:00","updated_at":"2023-12-14T15:20:59.209084439+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T15:20:59.209148651+01:00","hash":"","question":{"id":"517e8eac-8e11-4f08-bea0-92955836501e","created_at":"2023-12-14T15:20:59.209133538+01:00","updated_at":"2023-12-14T15:20:59.209133633+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_40b8222c-e969-4d80-b467-91b9c9f36baa.json b/cmd/probo-cli/testdata.bk/exams/exam_40b8222c-e969-4d80-b467-91b9c9f36baa.json new file mode 100644 index 0000000..cde4179 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_40b8222c-e969-4d80-b467-91b9c9f36baa.json @@ -0,0 +1 @@ +{"id":"40b8222c-e969-4d80-b467-91b9c9f36baa","created_at":"2023-12-14T17:45:08.914625496+01:00","updated_at":"2023-12-14T17:45:08.914625611+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:45:08.904532708+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:45:08.90479115+01:00","hash":"","question":{"id":"e878eed4-0c43-4de1-8133-ef6ebbaf2384","created_at":"2023-12-14T17:45:08.904769077+01:00","updated_at":"2023-12-14T17:45:08.904769207+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:45:08.904837105+01:00","hash":"","question":{"id":"d9c21113-dde7-4ad3-b786-14728ef5ef97","created_at":"2023-12-14T17:45:08.904826743+01:00","updated_at":"2023-12-14T17:45:08.904826836+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:45:08.904884568+01:00","hash":"","question":{"id":"d7aa0c14-c22d-4498-9f6c-385ebfcb5ec9","created_at":"2023-12-14T17:45:08.904870005+01:00","updated_at":"2023-12-14T17:45:08.904870076+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_4bb4d670-af9c-45b8-b556-2a330b684f0d.json b/cmd/probo-cli/testdata.bk/exams/exam_4bb4d670-af9c-45b8-b556-2a330b684f0d.json new file mode 100644 index 0000000..7beb4c6 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_4bb4d670-af9c-45b8-b556-2a330b684f0d.json @@ -0,0 +1 @@ +{"id":"4bb4d670-af9c-45b8-b556-2a330b684f0d","created_at":"2023-12-13T20:43:39.009584136+01:00","updated_at":"2023-12-14T17:45:08.905759267+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-13T20:43:39.009313483+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-13T20:43:39.009466213+01:00","hash":"","question":{"id":"1446034f-0166-420f-9ea7-ba76a7ea4946","created_at":"2023-12-13T20:43:39.009446789+01:00","updated_at":"2023-12-13T20:43:39.009446911+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-13T20:43:39.009513748+01:00","hash":"","question":{"id":"505007d7-b1e7-4079-a3f1-4e455118a385","created_at":"2023-12-13T20:43:39.009503106+01:00","updated_at":"2023-12-13T20:43:39.009503209+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-13T20:43:39.009567286+01:00","hash":"","question":{"id":"76486c50-a57e-4904-b93d-180847e110a1","created_at":"2023-12-13T20:43:39.009552462+01:00","updated_at":"2023-12-13T20:43:39.009552558+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_4d3a6924-bdc9-4bf3-b136-41591cf88cb6.json b/cmd/probo-cli/testdata.bk/exams/exam_4d3a6924-bdc9-4bf3-b136-41591cf88cb6.json new file mode 100644 index 0000000..0603e6c --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_4d3a6924-bdc9-4bf3-b136-41591cf88cb6.json @@ -0,0 +1 @@ +{"id":"4d3a6924-bdc9-4bf3-b136-41591cf88cb6","created_at":"2023-12-14T17:00:17.485867459+01:00","updated_at":"2023-12-14T17:45:08.905886974+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:00:17.479388096+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:00:17.479547595+01:00","hash":"","question":{"id":"ddb3f7ab-bc37-46fe-9a2a-c2edab54b601","created_at":"2023-12-14T17:00:17.479526534+01:00","updated_at":"2023-12-14T17:00:17.479526658+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:00:17.479617186+01:00","hash":"","question":{"id":"382b3b94-d171-4b90-9b72-20f9e40c659f","created_at":"2023-12-14T17:00:17.479584405+01:00","updated_at":"2023-12-14T17:00:17.479584483+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:00:17.479674172+01:00","hash":"","question":{"id":"b22988f9-c310-429d-97b4-3bc04c055e1a","created_at":"2023-12-14T17:00:17.479658787+01:00","updated_at":"2023-12-14T17:00:17.479658852+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_53a36e9b-0c81-4540-ab1e-55bb3b854f7b.json b/cmd/probo-cli/testdata.bk/exams/exam_53a36e9b-0c81-4540-ab1e-55bb3b854f7b.json new file mode 100644 index 0000000..bb0edc5 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_53a36e9b-0c81-4540-ab1e-55bb3b854f7b.json @@ -0,0 +1 @@ +{"id":"53a36e9b-0c81-4540-ab1e-55bb3b854f7b","created_at":"2023-12-14T17:41:35.25271621+01:00","updated_at":"2023-12-14T17:45:08.910743916+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:35.242986665+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:35.24313386+01:00","hash":"","question":{"id":"4bf59488-f1aa-475c-b5db-b91d5c6fdc2c","created_at":"2023-12-14T17:41:35.243111562+01:00","updated_at":"2023-12-14T17:41:35.243111677+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:35.243180207+01:00","hash":"","question":{"id":"ea042d30-4b97-4fde-a480-4e9560ad0008","created_at":"2023-12-14T17:41:35.243169737+01:00","updated_at":"2023-12-14T17:41:35.24316983+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:35.243228593+01:00","hash":"","question":{"id":"daa5e687-bb35-4cf6-96b9-ccace1fb490f","created_at":"2023-12-14T17:41:35.243213836+01:00","updated_at":"2023-12-14T17:41:35.243213901+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_563f99bd-b2b5-4427-b741-02bf362db5cf.json b/cmd/probo-cli/testdata.bk/exams/exam_563f99bd-b2b5-4427-b741-02bf362db5cf.json new file mode 100644 index 0000000..0682821 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_563f99bd-b2b5-4427-b741-02bf362db5cf.json @@ -0,0 +1 @@ +{"id":"563f99bd-b2b5-4427-b741-02bf362db5cf","created_at":"2023-12-14T17:06:10.084568599+01:00","updated_at":"2023-12-14T17:45:08.910886585+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:06:10.07609401+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:06:10.07637237+01:00","hash":"","question":{"id":"51c07172-2ed8-4677-bb6f-d881714ded9b","created_at":"2023-12-14T17:06:10.076351886+01:00","updated_at":"2023-12-14T17:06:10.076352015+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:06:10.076421327+01:00","hash":"","question":{"id":"2204fa34-4c3d-4348-9f13-dad2cc89e0bf","created_at":"2023-12-14T17:06:10.076410271+01:00","updated_at":"2023-12-14T17:06:10.076410369+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:06:10.076682973+01:00","hash":"","question":{"id":"99e9fcd9-4acc-4ff4-9f92-09df8ebe4559","created_at":"2023-12-14T17:06:10.076667178+01:00","updated_at":"2023-12-14T17:06:10.076667256+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},{"id":"f2f3e339-6c7d-4b66-acb3-d7168598ccda","created_at":"2023-12-14T17:06:10.076354528+01:00","updated_at":"2023-12-14T17:06:10.076354629+01:00","text":"Giuly (❤️)"},{"id":"8695d448-d76d-42e5-9f78-40d4b24ef603","created_at":"2023-12-14T17:06:10.076357931+01:00","updated_at":"2023-12-14T17:06:10.076357997+01:00","text":"Jenny"},{"id":"14bea8ce-86df-430f-92a7-9d5f0bf1c3f6","created_at":"2023-12-14T17:06:10.076359429+01:00","updated_at":"2023-12-14T17:06:10.076359472+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"90d7048e-39e5-4089-815e-7b742898c09e","created_at":"2023-12-14T17:06:10.076356394+01:00","updated_at":"2023-12-14T17:06:10.076356436+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_57e7a11a-5b96-4329-be3b-13270a11cb9f.json b/cmd/probo-cli/testdata.bk/exams/exam_57e7a11a-5b96-4329-be3b-13270a11cb9f.json new file mode 100644 index 0000000..533f51b --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_57e7a11a-5b96-4329-be3b-13270a11cb9f.json @@ -0,0 +1 @@ +{"id":"57e7a11a-5b96-4329-be3b-13270a11cb9f","created_at":"2023-12-14T17:05:57.284842134+01:00","updated_at":"2023-12-14T17:45:08.911016874+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:05:57.276640096+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:05:57.27688532+01:00","hash":"","question":{"id":"12727ba0-9ccc-430e-9919-fbacb7f032d2","created_at":"2023-12-14T17:05:57.276869592+01:00","updated_at":"2023-12-14T17:05:57.276869653+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:05:57.276792157+01:00","hash":"","question":{"id":"4d83355e-6bd3-4c63-be23-3115debe5462","created_at":"2023-12-14T17:05:57.276769264+01:00","updated_at":"2023-12-14T17:05:57.276769398+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:05:57.276838779+01:00","hash":"","question":{"id":"d0561675-0643-498b-b495-7ea351aeb027","created_at":"2023-12-14T17:05:57.276828009+01:00","updated_at":"2023-12-14T17:05:57.276828098+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},{"id":"fa5dbbb2-24d6-4ff6-85b2-5edeb5a1f789","created_at":"2023-12-14T17:05:57.276779543+01:00","updated_at":"2023-12-14T17:05:57.276779584+01:00","text":"Jenny"},{"id":"6def181e-9851-431c-b83a-92a33a22cfc1","created_at":"2023-12-14T17:05:57.276776149+01:00","updated_at":"2023-12-14T17:05:57.276776242+01:00","text":"Giuly (❤️)"},{"id":"964abe49-06be-4310-8178-54146117d18c","created_at":"2023-12-14T17:05:57.276781041+01:00","updated_at":"2023-12-14T17:05:57.276781082+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fb5efe56-3836-460e-bd7c-16b80d170d67","created_at":"2023-12-14T17:05:57.276777945+01:00","updated_at":"2023-12-14T17:05:57.276777988+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_5bf90820-9ee8-4e25-a9c5-9ba028a5fd36.json b/cmd/probo-cli/testdata.bk/exams/exam_5bf90820-9ee8-4e25-a9c5-9ba028a5fd36.json new file mode 100644 index 0000000..c8961fb --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_5bf90820-9ee8-4e25-a9c5-9ba028a5fd36.json @@ -0,0 +1 @@ +{"id":"5bf90820-9ee8-4e25-a9c5-9ba028a5fd36","created_at":"2023-12-14T17:05:25.605363888+01:00","updated_at":"2023-12-14T17:45:08.911151586+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:05:25.597382281+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:05:25.597711652+01:00","hash":"","question":{"id":"5a4cb35e-f476-4670-acdb-77b6b70c3d62","created_at":"2023-12-14T17:05:25.597700847+01:00","updated_at":"2023-12-14T17:05:25.597700936+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:05:25.597759649+01:00","hash":"","question":{"id":"7ed005f0-f894-426b-a0e3-ed05742fc296","created_at":"2023-12-14T17:05:25.597743337+01:00","updated_at":"2023-12-14T17:05:25.597743428+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:05:25.597663536+01:00","hash":"","question":{"id":"86be6735-aff3-41c4-80c2-7edf03ced058","created_at":"2023-12-14T17:05:25.59764423+01:00","updated_at":"2023-12-14T17:05:25.597644376+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_69bb12a7-5e05-426f-b975-e5d753bd0e59.json b/cmd/probo-cli/testdata.bk/exams/exam_69bb12a7-5e05-426f-b975-e5d753bd0e59.json new file mode 100644 index 0000000..1c50ba6 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_69bb12a7-5e05-426f-b975-e5d753bd0e59.json @@ -0,0 +1 @@ +{"id":"69bb12a7-5e05-426f-b975-e5d753bd0e59","created_at":"2023-12-14T17:41:35.252639275+01:00","updated_at":"2023-12-14T17:45:08.911276739+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:35.24286302+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:35.24313386+01:00","hash":"","question":{"id":"4bf59488-f1aa-475c-b5db-b91d5c6fdc2c","created_at":"2023-12-14T17:41:35.243111562+01:00","updated_at":"2023-12-14T17:41:35.243111677+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:35.243180207+01:00","hash":"","question":{"id":"ea042d30-4b97-4fde-a480-4e9560ad0008","created_at":"2023-12-14T17:41:35.243169737+01:00","updated_at":"2023-12-14T17:41:35.24316983+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:35.243228593+01:00","hash":"","question":{"id":"daa5e687-bb35-4cf6-96b9-ccace1fb490f","created_at":"2023-12-14T17:41:35.243213836+01:00","updated_at":"2023-12-14T17:41:35.243213901+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},{"id":"fe63f02f-2381-496a-8de9-af7e70de3d15","created_at":"2023-12-14T17:41:35.243114731+01:00","updated_at":"2023-12-14T17:41:35.243114822+01:00","text":"Giuly (❤️)"},{"id":"39cb34e9-73e3-4924-bc42-34384942244c","created_at":"2023-12-14T17:41:35.243118139+01:00","updated_at":"2023-12-14T17:41:35.243118179+01:00","text":"Jenny"},{"id":"fa07c49d-f3e7-4766-ba34-fa9f085b8c98","created_at":"2023-12-14T17:41:35.243119635+01:00","updated_at":"2023-12-14T17:41:35.243119677+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"dbf82a73-5bcf-4e86-8231-eec7f8e10734","created_at":"2023-12-14T17:41:35.243116503+01:00","updated_at":"2023-12-14T17:41:35.243116565+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_6a14a5a0-c13d-4819-9d35-96f1bfff821a.json b/cmd/probo-cli/testdata.bk/exams/exam_6a14a5a0-c13d-4819-9d35-96f1bfff821a.json new file mode 100644 index 0000000..c41949a --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_6a14a5a0-c13d-4819-9d35-96f1bfff821a.json @@ -0,0 +1 @@ +{"id":"6a14a5a0-c13d-4819-9d35-96f1bfff821a","created_at":"2023-12-14T16:58:58.791515853+01:00","updated_at":"2023-12-14T17:45:08.911398611+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:58:58.789717745+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:58:58.789870342+01:00","hash":"","question":{"id":"bb436e89-ecfd-4422-a109-84cf22491f3f","created_at":"2023-12-14T16:58:58.789851155+01:00","updated_at":"2023-12-14T16:58:58.789851302+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:58:58.789917613+01:00","hash":"","question":{"id":"4d8796d3-f2d4-4ded-abb1-feeb7a36b1ab","created_at":"2023-12-14T16:58:58.789906814+01:00","updated_at":"2023-12-14T16:58:58.789906939+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:58:58.7899646+01:00","hash":"","question":{"id":"6d0a3106-2878-488a-9e07-bb99213b6c39","created_at":"2023-12-14T16:58:58.789948487+01:00","updated_at":"2023-12-14T16:58:58.789948551+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_7813d5dd-c50f-4591-b63b-67dc3929ac3d.json b/cmd/probo-cli/testdata.bk/exams/exam_7813d5dd-c50f-4591-b63b-67dc3929ac3d.json new file mode 100644 index 0000000..202652c --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_7813d5dd-c50f-4591-b63b-67dc3929ac3d.json @@ -0,0 +1 @@ +{"id":"7813d5dd-c50f-4591-b63b-67dc3929ac3d","created_at":"2023-12-14T17:41:41.952469039+01:00","updated_at":"2023-12-14T17:45:08.911534273+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:41.942746068+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:41.942903992+01:00","hash":"","question":{"id":"5e276bc7-041a-4aea-ae5c-56a27389ef28","created_at":"2023-12-14T17:41:41.942880464+01:00","updated_at":"2023-12-14T17:41:41.942880611+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:41.942952987+01:00","hash":"","question":{"id":"11bd2140-de40-40b7-9251-e58ee090ffd5","created_at":"2023-12-14T17:41:41.942942021+01:00","updated_at":"2023-12-14T17:41:41.94294213+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:41.943010966+01:00","hash":"","question":{"id":"d9a041e2-5b9d-4dc2-914c-535ec1834031","created_at":"2023-12-14T17:41:41.942988471+01:00","updated_at":"2023-12-14T17:41:41.94298853+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_7d6aa89f-b10f-4fef-8dd6-a96a97a83d1c.json b/cmd/probo-cli/testdata.bk/exams/exam_7d6aa89f-b10f-4fef-8dd6-a96a97a83d1c.json new file mode 100644 index 0000000..516ee30 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_7d6aa89f-b10f-4fef-8dd6-a96a97a83d1c.json @@ -0,0 +1 @@ +{"id":"7d6aa89f-b10f-4fef-8dd6-a96a97a83d1c","created_at":"2023-12-14T17:02:28.126667167+01:00","updated_at":"2023-12-14T17:45:08.911661672+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:02:28.119032845+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:02:28.119227972+01:00","hash":"","question":{"id":"62c6b43b-f625-4d96-a382-cc8dae59a4c4","created_at":"2023-12-14T17:02:28.119217297+01:00","updated_at":"2023-12-14T17:02:28.119217391+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:02:28.119274182+01:00","hash":"","question":{"id":"3107c02e-e5c3-4417-be04-e4e5ada26052","created_at":"2023-12-14T17:02:28.11925844+01:00","updated_at":"2023-12-14T17:02:28.119258524+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:02:28.119181757+01:00","hash":"","question":{"id":"d39864ed-d197-4023-a9cc-7b4941d1d6e9","created_at":"2023-12-14T17:02:28.119164296+01:00","updated_at":"2023-12-14T17:02:28.119164423+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_7f8aaa16-1ec3-465d-97a8-845e7e6028d3.json b/cmd/probo-cli/testdata.bk/exams/exam_7f8aaa16-1ec3-465d-97a8-845e7e6028d3.json new file mode 100644 index 0000000..8bee45d --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_7f8aaa16-1ec3-465d-97a8-845e7e6028d3.json @@ -0,0 +1 @@ +{"id":"7f8aaa16-1ec3-465d-97a8-845e7e6028d3","created_at":"2023-12-14T17:05:25.60543658+01:00","updated_at":"2023-12-14T17:45:08.911846693+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:05:25.59750947+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:05:25.597663536+01:00","hash":"","question":{"id":"86be6735-aff3-41c4-80c2-7edf03ced058","created_at":"2023-12-14T17:05:25.59764423+01:00","updated_at":"2023-12-14T17:05:25.597644376+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:05:25.597711652+01:00","hash":"","question":{"id":"5a4cb35e-f476-4670-acdb-77b6b70c3d62","created_at":"2023-12-14T17:05:25.597700847+01:00","updated_at":"2023-12-14T17:05:25.597700936+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:05:25.597759649+01:00","hash":"","question":{"id":"7ed005f0-f894-426b-a0e3-ed05742fc296","created_at":"2023-12-14T17:05:25.597743337+01:00","updated_at":"2023-12-14T17:05:25.597743428+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},{"id":"af2494c7-5746-4c22-8b4f-5de296321197","created_at":"2023-12-14T17:05:25.597646823+01:00","updated_at":"2023-12-14T17:05:25.59764692+01:00","text":"Giuly (❤️)"},{"id":"41840f7c-5616-44a5-bf39-1fceb03971f0","created_at":"2023-12-14T17:05:25.597650137+01:00","updated_at":"2023-12-14T17:05:25.597650178+01:00","text":"Jenny"},{"id":"8e884ab0-f6d2-41fc-8a08-7af3d5b8cb7f","created_at":"2023-12-14T17:05:25.597651666+01:00","updated_at":"2023-12-14T17:05:25.597651732+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8f17e51e-7256-4166-938c-24586ee08a4e","created_at":"2023-12-14T17:05:25.59764859+01:00","updated_at":"2023-12-14T17:05:25.597648632+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_8568e115-cc96-43e6-859c-966bdfc10c61.json b/cmd/probo-cli/testdata.bk/exams/exam_8568e115-cc96-43e6-859c-966bdfc10c61.json new file mode 100644 index 0000000..2b19409 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_8568e115-cc96-43e6-859c-966bdfc10c61.json @@ -0,0 +1 @@ +{"id":"8568e115-cc96-43e6-859c-966bdfc10c61","created_at":"2023-12-14T17:00:17.485975416+01:00","updated_at":"2023-12-14T17:45:08.911972231+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:00:17.479257686+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:00:17.479674172+01:00","hash":"","question":{"id":"b22988f9-c310-429d-97b4-3bc04c055e1a","created_at":"2023-12-14T17:00:17.479658787+01:00","updated_at":"2023-12-14T17:00:17.479658852+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:00:17.479547595+01:00","hash":"","question":{"id":"ddb3f7ab-bc37-46fe-9a2a-c2edab54b601","created_at":"2023-12-14T17:00:17.479526534+01:00","updated_at":"2023-12-14T17:00:17.479526658+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:00:17.479617186+01:00","hash":"","question":{"id":"382b3b94-d171-4b90-9b72-20f9e40c659f","created_at":"2023-12-14T17:00:17.479584405+01:00","updated_at":"2023-12-14T17:00:17.479584483+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},{"id":"2fd91f58-1b14-4088-af28-91782883b70d","created_at":"2023-12-14T17:00:17.479532399+01:00","updated_at":"2023-12-14T17:00:17.47953244+01:00","text":"Jenny"},{"id":"a295b8e5-e3c5-44a5-bbf4-44b624b9ec6f","created_at":"2023-12-14T17:00:17.479529068+01:00","updated_at":"2023-12-14T17:00:17.479529163+01:00","text":"Giuly (❤️)"},{"id":"e45e421f-6612-46be-84d2-b641a254c583","created_at":"2023-12-14T17:00:17.479533969+01:00","updated_at":"2023-12-14T17:00:17.47953401+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"c1cd2806-3411-4230-bfef-efc6b38f2d97","created_at":"2023-12-14T17:00:17.479530868+01:00","updated_at":"2023-12-14T17:00:17.47953092+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_861aa787-f611-4a31-8e05-ec7cff884a2d.json b/cmd/probo-cli/testdata.bk/exams/exam_861aa787-f611-4a31-8e05-ec7cff884a2d.json new file mode 100644 index 0000000..038307f --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_861aa787-f611-4a31-8e05-ec7cff884a2d.json @@ -0,0 +1 @@ +{"id":"861aa787-f611-4a31-8e05-ec7cff884a2d","created_at":"2023-12-13T20:43:39.009733404+01:00","updated_at":"2023-12-14T17:45:08.912093817+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-13T20:43:39.0091841+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-13T20:43:39.009466213+01:00","hash":"","question":{"id":"1446034f-0166-420f-9ea7-ba76a7ea4946","created_at":"2023-12-13T20:43:39.009446789+01:00","updated_at":"2023-12-13T20:43:39.009446911+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-13T20:43:39.009513748+01:00","hash":"","question":{"id":"505007d7-b1e7-4079-a3f1-4e455118a385","created_at":"2023-12-13T20:43:39.009503106+01:00","updated_at":"2023-12-13T20:43:39.009503209+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-13T20:43:39.009567286+01:00","hash":"","question":{"id":"76486c50-a57e-4904-b93d-180847e110a1","created_at":"2023-12-13T20:43:39.009552462+01:00","updated_at":"2023-12-13T20:43:39.009552558+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},{"id":"5beb6a3b-ce2c-48c9-8cf0-b40569b27f1b","created_at":"2023-12-13T20:43:39.009449037+01:00","updated_at":"2023-12-13T20:43:39.009449136+01:00","text":"Giuly (❤️)"},{"id":"77e0a85f-5e56-4188-88c7-6b7813b9d43d","created_at":"2023-12-13T20:43:39.009452278+01:00","updated_at":"2023-12-13T20:43:39.009452322+01:00","text":"Jenny"},{"id":"9d12c29d-fa3a-4bb6-b207-b0032b8e536f","created_at":"2023-12-13T20:43:39.009453758+01:00","updated_at":"2023-12-13T20:43:39.009453802+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"3a7258fc-d59c-40b6-ad78-cd40705d851b","created_at":"2023-12-13T20:43:39.009450785+01:00","updated_at":"2023-12-13T20:43:39.009450829+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_88182c1f-8cba-42d2-ac91-a5a228bb267e.json b/cmd/probo-cli/testdata.bk/exams/exam_88182c1f-8cba-42d2-ac91-a5a228bb267e.json new file mode 100644 index 0000000..6dceb2a --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_88182c1f-8cba-42d2-ac91-a5a228bb267e.json @@ -0,0 +1 @@ +{"id":"88182c1f-8cba-42d2-ac91-a5a228bb267e","created_at":"2023-12-14T17:41:20.704023413+01:00","updated_at":"2023-12-14T17:45:08.912217815+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:20.694833793+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:20.6951014+01:00","hash":"","question":{"id":"d6177fea-44f3-4fee-9b62-e25aa538e185","created_at":"2023-12-14T17:41:20.695078549+01:00","updated_at":"2023-12-14T17:41:20.695078681+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:20.695148748+01:00","hash":"","question":{"id":"bd5dd43d-3fe4-4742-ada6-639d08ddc89f","created_at":"2023-12-14T17:41:20.695138077+01:00","updated_at":"2023-12-14T17:41:20.695138172+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:20.695198069+01:00","hash":"","question":{"id":"1aa48d1b-db29-43d5-9d35-124cfb5a529c","created_at":"2023-12-14T17:41:20.695183093+01:00","updated_at":"2023-12-14T17:41:20.69518316+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_8b0b31cc-4d71-4ef9-b86b-444e5432910d.json b/cmd/probo-cli/testdata.bk/exams/exam_8b0b31cc-4d71-4ef9-b86b-444e5432910d.json new file mode 100644 index 0000000..2545244 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_8b0b31cc-4d71-4ef9-b86b-444e5432910d.json @@ -0,0 +1 @@ +{"id":"8b0b31cc-4d71-4ef9-b86b-444e5432910d","created_at":"2023-12-14T17:08:01.388740521+01:00","updated_at":"2023-12-14T17:45:08.912340489+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:08:01.37376218+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:08:01.373906144+01:00","hash":"","question":{"id":"1f961c2e-fc65-41e4-ae38-a18dab0b42f9","created_at":"2023-12-14T17:08:01.373883056+01:00","updated_at":"2023-12-14T17:08:01.373883179+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:08:01.373956214+01:00","hash":"","question":{"id":"217941b2-6469-4d2c-b0d1-ab9eeddea35d","created_at":"2023-12-14T17:08:01.373945394+01:00","updated_at":"2023-12-14T17:08:01.373945485+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:08:01.37400563+01:00","hash":"","question":{"id":"5bf0ff15-109b-4dd0-b539-0cab1e2d9b2c","created_at":"2023-12-14T17:08:01.37399516+01:00","updated_at":"2023-12-14T17:08:01.373995232+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_8b2c7934-bb43-45e9-b81e-fd46a109bf69.json b/cmd/probo-cli/testdata.bk/exams/exam_8b2c7934-bb43-45e9-b81e-fd46a109bf69.json new file mode 100644 index 0000000..5eec221 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_8b2c7934-bb43-45e9-b81e-fd46a109bf69.json @@ -0,0 +1 @@ +{"id":"8b2c7934-bb43-45e9-b81e-fd46a109bf69","created_at":"2023-12-14T17:07:52.035951855+01:00","updated_at":"2023-12-14T17:45:08.912462175+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:07:52.025617026+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:07:52.025956869+01:00","hash":"","question":{"id":"d886140d-76bc-4225-94bf-6c5eb597c561","created_at":"2023-12-14T17:07:52.025923438+01:00","updated_at":"2023-12-14T17:07:52.025923609+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:07:52.026034589+01:00","hash":"","question":{"id":"3cd661fd-2c01-49af-b8e8-38b1cc9823a4","created_at":"2023-12-14T17:07:52.026014854+01:00","updated_at":"2023-12-14T17:07:52.026014982+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:07:52.026117153+01:00","hash":"","question":{"id":"628e2604-88dd-4748-b927-002bf26cd745","created_at":"2023-12-14T17:07:52.026093354+01:00","updated_at":"2023-12-14T17:07:52.026093447+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_8dfcac20-0ff5-471d-add5-b622ebc12e80.json b/cmd/probo-cli/testdata.bk/exams/exam_8dfcac20-0ff5-471d-add5-b622ebc12e80.json new file mode 100644 index 0000000..5d61c92 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_8dfcac20-0ff5-471d-add5-b622ebc12e80.json @@ -0,0 +1 @@ +{"id":"8dfcac20-0ff5-471d-add5-b622ebc12e80","created_at":"2023-12-14T17:43:18.126964422+01:00","updated_at":"2023-12-14T17:45:08.912584126+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:43:18.104944772+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:43:18.105224643+01:00","hash":"","question":{"id":"9aadd35f-b345-42b7-8d6d-627f279a16d9","created_at":"2023-12-14T17:43:18.105199556+01:00","updated_at":"2023-12-14T17:43:18.105199698+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:43:18.10527206+01:00","hash":"","question":{"id":"9531429d-dd38-4d21-820b-bf2ba1177a91","created_at":"2023-12-14T17:43:18.105261438+01:00","updated_at":"2023-12-14T17:43:18.105261513+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:43:18.105321478+01:00","hash":"","question":{"id":"afdee6d2-5dae-445f-91e6-4fe71f163032","created_at":"2023-12-14T17:43:18.105306543+01:00","updated_at":"2023-12-14T17:43:18.105306605+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},{"id":"eb3b25e2-331c-4cb2-ba1c-70fb7a286217","created_at":"2023-12-14T17:43:18.105202738+01:00","updated_at":"2023-12-14T17:43:18.105202831+01:00","text":"Giuly (❤️)"},{"id":"aaeb4fa9-8b6c-48b3-8267-c2f0830c4e24","created_at":"2023-12-14T17:43:18.105206191+01:00","updated_at":"2023-12-14T17:43:18.10520625+01:00","text":"Jenny"},{"id":"d95d86e2-ed72-4081-b00c-0e9f9598814a","created_at":"2023-12-14T17:43:18.105207866+01:00","updated_at":"2023-12-14T17:43:18.105207907+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6fa782c8-076d-4cec-83e8-d9f9010d71b3","created_at":"2023-12-14T17:43:18.105204547+01:00","updated_at":"2023-12-14T17:43:18.105204588+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_9208c855-6b05-4eb3-81a7-bfb44a701594.json b/cmd/probo-cli/testdata.bk/exams/exam_9208c855-6b05-4eb3-81a7-bfb44a701594.json new file mode 100644 index 0000000..956afa2 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_9208c855-6b05-4eb3-81a7-bfb44a701594.json @@ -0,0 +1 @@ +{"id":"9208c855-6b05-4eb3-81a7-bfb44a701594","created_at":"2023-12-14T16:55:53.825548971+01:00","updated_at":"2023-12-14T17:45:08.912705702+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:55:53.81931097+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:55:53.819459933+01:00","hash":"","question":{"id":"79942ec7-ee30-45d3-964e-c2ade6f05024","created_at":"2023-12-14T16:55:53.819438467+01:00","updated_at":"2023-12-14T16:55:53.819438607+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:55:53.819507024+01:00","hash":"","question":{"id":"87c806cd-e72b-4793-95d1-dbe887b9a881","created_at":"2023-12-14T16:55:53.819496215+01:00","updated_at":"2023-12-14T16:55:53.8194963+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:55:53.819561771+01:00","hash":"","question":{"id":"4c661148-87ec-4387-ae66-fae354933a96","created_at":"2023-12-14T16:55:53.819545049+01:00","updated_at":"2023-12-14T16:55:53.819545098+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_95c7cf92-8c92-4b9f-bb8b-1ead62c771a2.json b/cmd/probo-cli/testdata.bk/exams/exam_95c7cf92-8c92-4b9f-bb8b-1ead62c771a2.json new file mode 100644 index 0000000..89eec4c --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_95c7cf92-8c92-4b9f-bb8b-1ead62c771a2.json @@ -0,0 +1 @@ +{"id":"95c7cf92-8c92-4b9f-bb8b-1ead62c771a2","created_at":"2023-12-14T17:41:41.952402028+01:00","updated_at":"2023-12-14T17:45:08.912828952+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:41.942560673+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:41.942903992+01:00","hash":"","question":{"id":"5e276bc7-041a-4aea-ae5c-56a27389ef28","created_at":"2023-12-14T17:41:41.942880464+01:00","updated_at":"2023-12-14T17:41:41.942880611+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:41.942952987+01:00","hash":"","question":{"id":"11bd2140-de40-40b7-9251-e58ee090ffd5","created_at":"2023-12-14T17:41:41.942942021+01:00","updated_at":"2023-12-14T17:41:41.94294213+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:41.943010966+01:00","hash":"","question":{"id":"d9a041e2-5b9d-4dc2-914c-535ec1834031","created_at":"2023-12-14T17:41:41.942988471+01:00","updated_at":"2023-12-14T17:41:41.94298853+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},{"id":"0d4c0592-dd0f-48ce-b942-2418b1613e22","created_at":"2023-12-14T17:41:41.942884367+01:00","updated_at":"2023-12-14T17:41:41.942884463+01:00","text":"Giuly (❤️)"},{"id":"1932282b-5c5b-4c40-ba90-1ab3565a5130","created_at":"2023-12-14T17:41:41.942887717+01:00","updated_at":"2023-12-14T17:41:41.94288776+01:00","text":"Jenny"},{"id":"19053941-5944-4c88-a566-d5e6ecf60d11","created_at":"2023-12-14T17:41:41.942889268+01:00","updated_at":"2023-12-14T17:41:41.942889311+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"795b4350-edff-42b9-9920-90f585b9fb59","created_at":"2023-12-14T17:41:41.942886125+01:00","updated_at":"2023-12-14T17:41:41.942886191+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_983b9fb6-c00e-4ccf-87fa-bc88a1d036d6.json b/cmd/probo-cli/testdata.bk/exams/exam_983b9fb6-c00e-4ccf-87fa-bc88a1d036d6.json new file mode 100644 index 0000000..5956dde --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_983b9fb6-c00e-4ccf-87fa-bc88a1d036d6.json @@ -0,0 +1 @@ +{"id":"983b9fb6-c00e-4ccf-87fa-bc88a1d036d6","created_at":"2023-12-14T16:00:21.20552267+01:00","updated_at":"2023-12-14T17:45:08.91295036+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:00:21.204186117+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:00:21.204331154+01:00","hash":"","question":{"id":"bb14d3e5-90db-41d7-a74d-9d1db1a3737a","created_at":"2023-12-14T16:00:21.204311945+01:00","updated_at":"2023-12-14T16:00:21.204312065+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:00:21.204378186+01:00","hash":"","question":{"id":"2573ef1b-5ef3-481f-8768-bf9bcd47a771","created_at":"2023-12-14T16:00:21.204367436+01:00","updated_at":"2023-12-14T16:00:21.204367524+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:00:21.204430057+01:00","hash":"","question":{"id":"16f8ac03-b042-4adb-b9d3-7c83a7523f5b","created_at":"2023-12-14T16:00:21.204415375+01:00","updated_at":"2023-12-14T16:00:21.204415452+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_a89835cb-52ef-4ebb-9101-ae0dbf1da81c.json b/cmd/probo-cli/testdata.bk/exams/exam_a89835cb-52ef-4ebb-9101-ae0dbf1da81c.json new file mode 100644 index 0000000..b680b1b --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_a89835cb-52ef-4ebb-9101-ae0dbf1da81c.json @@ -0,0 +1 @@ +{"id":"a89835cb-52ef-4ebb-9101-ae0dbf1da81c","created_at":"2023-12-14T16:55:53.825473863+01:00","updated_at":"2023-12-14T17:45:08.913073883+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:55:53.819169632+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:55:53.819459933+01:00","hash":"","question":{"id":"79942ec7-ee30-45d3-964e-c2ade6f05024","created_at":"2023-12-14T16:55:53.819438467+01:00","updated_at":"2023-12-14T16:55:53.819438607+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:55:53.819507024+01:00","hash":"","question":{"id":"87c806cd-e72b-4793-95d1-dbe887b9a881","created_at":"2023-12-14T16:55:53.819496215+01:00","updated_at":"2023-12-14T16:55:53.8194963+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:55:53.819561771+01:00","hash":"","question":{"id":"4c661148-87ec-4387-ae66-fae354933a96","created_at":"2023-12-14T16:55:53.819545049+01:00","updated_at":"2023-12-14T16:55:53.819545098+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},{"id":"7c2cc65f-7ec7-472f-8115-7a90f45c7a2e","created_at":"2023-12-14T16:55:53.819441427+01:00","updated_at":"2023-12-14T16:55:53.819441522+01:00","text":"Giuly (❤️)"},{"id":"f6a7b009-2c9e-47e7-8e30-a7140892c4f4","created_at":"2023-12-14T16:55:53.819444627+01:00","updated_at":"2023-12-14T16:55:53.819444668+01:00","text":"Jenny"},{"id":"a30e8e08-2c5a-4034-b64f-ae5780eb24dc","created_at":"2023-12-14T16:55:53.819446033+01:00","updated_at":"2023-12-14T16:55:53.819446075+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"2bd9a104-cff3-48d3-94c2-75a14be5ae5b","created_at":"2023-12-14T16:55:53.819443109+01:00","updated_at":"2023-12-14T16:55:53.819443151+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_b0bda8b2-282e-423d-b585-a4d99eecdd85.json b/cmd/probo-cli/testdata.bk/exams/exam_b0bda8b2-282e-423d-b585-a4d99eecdd85.json new file mode 100644 index 0000000..a99b3d2 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_b0bda8b2-282e-423d-b585-a4d99eecdd85.json @@ -0,0 +1 @@ +{"id":"b0bda8b2-282e-423d-b585-a4d99eecdd85","created_at":"2023-12-14T17:45:08.914690522+01:00","updated_at":"2023-12-14T17:45:08.914690625+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:45:08.904646212+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:45:08.90479115+01:00","hash":"","question":{"id":"e878eed4-0c43-4de1-8133-ef6ebbaf2384","created_at":"2023-12-14T17:45:08.904769077+01:00","updated_at":"2023-12-14T17:45:08.904769207+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:45:08.904837105+01:00","hash":"","question":{"id":"d9c21113-dde7-4ad3-b786-14728ef5ef97","created_at":"2023-12-14T17:45:08.904826743+01:00","updated_at":"2023-12-14T17:45:08.904826836+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:45:08.904884568+01:00","hash":"","question":{"id":"d7aa0c14-c22d-4498-9f6c-385ebfcb5ec9","created_at":"2023-12-14T17:45:08.904870005+01:00","updated_at":"2023-12-14T17:45:08.904870076+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},{"id":"8cca3337-f0b4-4bcf-9a94-9df0aa3d6df5","created_at":"2023-12-14T17:45:08.904772176+01:00","updated_at":"2023-12-14T17:45:08.904772274+01:00","text":"Giuly (❤️)"},{"id":"479cb79d-bade-4578-aa08-77f5032b0b7d","created_at":"2023-12-14T17:45:08.904775421+01:00","updated_at":"2023-12-14T17:45:08.904775471+01:00","text":"Jenny"},{"id":"7d4ac008-62f9-41b0-b2ce-d70b83a59645","created_at":"2023-12-14T17:45:08.904777014+01:00","updated_at":"2023-12-14T17:45:08.904777054+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"60bc11e8-fadd-4319-8907-a034ac8c6460","created_at":"2023-12-14T17:45:08.904773906+01:00","updated_at":"2023-12-14T17:45:08.904773966+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_baf59465-a2ea-4086-83c4-192e1d2ece38.json b/cmd/probo-cli/testdata.bk/exams/exam_baf59465-a2ea-4086-83c4-192e1d2ece38.json new file mode 100644 index 0000000..d398a0d --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_baf59465-a2ea-4086-83c4-192e1d2ece38.json @@ -0,0 +1 @@ +{"id":"baf59465-a2ea-4086-83c4-192e1d2ece38","created_at":"2023-12-14T17:02:28.126597496+01:00","updated_at":"2023-12-14T17:45:08.913201404+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:02:28.118913332+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:02:28.119181757+01:00","hash":"","question":{"id":"d39864ed-d197-4023-a9cc-7b4941d1d6e9","created_at":"2023-12-14T17:02:28.119164296+01:00","updated_at":"2023-12-14T17:02:28.119164423+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:02:28.119227972+01:00","hash":"","question":{"id":"62c6b43b-f625-4d96-a382-cc8dae59a4c4","created_at":"2023-12-14T17:02:28.119217297+01:00","updated_at":"2023-12-14T17:02:28.119217391+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:02:28.119274182+01:00","hash":"","question":{"id":"3107c02e-e5c3-4417-be04-e4e5ada26052","created_at":"2023-12-14T17:02:28.11925844+01:00","updated_at":"2023-12-14T17:02:28.119258524+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},{"id":"b9e5c7a2-01c7-41c9-999e-5e796f1b33d0","created_at":"2023-12-14T17:02:28.119166862+01:00","updated_at":"2023-12-14T17:02:28.119166958+01:00","text":"Giuly (❤️)"},{"id":"b39d170c-dfec-43d9-9d4c-67599015e4af","created_at":"2023-12-14T17:02:28.119170154+01:00","updated_at":"2023-12-14T17:02:28.119170217+01:00","text":"Jenny"},{"id":"d69dec4c-28f7-4a69-a674-2dd10638116a","created_at":"2023-12-14T17:02:28.119171662+01:00","updated_at":"2023-12-14T17:02:28.119171706+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"797bf9ce-4365-4a5d-94c1-d47feaad50ad","created_at":"2023-12-14T17:02:28.119168616+01:00","updated_at":"2023-12-14T17:02:28.119168656+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_c1166a0b-d66b-4c7a-b60b-fc2f123df942.json b/cmd/probo-cli/testdata.bk/exams/exam_c1166a0b-d66b-4c7a-b60b-fc2f123df942.json new file mode 100644 index 0000000..9f47226 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_c1166a0b-d66b-4c7a-b60b-fc2f123df942.json @@ -0,0 +1 @@ +{"id":"c1166a0b-d66b-4c7a-b60b-fc2f123df942","created_at":"2023-12-14T16:00:21.205447972+01:00","updated_at":"2023-12-14T17:45:08.913325865+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:00:21.204078359+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:00:21.204331154+01:00","hash":"","question":{"id":"bb14d3e5-90db-41d7-a74d-9d1db1a3737a","created_at":"2023-12-14T16:00:21.204311945+01:00","updated_at":"2023-12-14T16:00:21.204312065+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:00:21.204378186+01:00","hash":"","question":{"id":"2573ef1b-5ef3-481f-8768-bf9bcd47a771","created_at":"2023-12-14T16:00:21.204367436+01:00","updated_at":"2023-12-14T16:00:21.204367524+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:00:21.204430057+01:00","hash":"","question":{"id":"16f8ac03-b042-4adb-b9d3-7c83a7523f5b","created_at":"2023-12-14T16:00:21.204415375+01:00","updated_at":"2023-12-14T16:00:21.204415452+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},{"id":"8e7a2da4-3e1d-4929-b322-730c5c615094","created_at":"2023-12-14T16:00:21.204314149+01:00","updated_at":"2023-12-14T16:00:21.204314235+01:00","text":"Giuly (❤️)"},{"id":"f3f0b876-13f6-4c8d-b66b-a70a609b36ca","created_at":"2023-12-14T16:00:21.204317478+01:00","updated_at":"2023-12-14T16:00:21.204317521+01:00","text":"Jenny"},{"id":"c8eab29b-4ccd-4d93-89a7-5bd77fd3c430","created_at":"2023-12-14T16:00:21.204318953+01:00","updated_at":"2023-12-14T16:00:21.204318996+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"84c36b3a-2261-4677-99c3-bb0091034be1","created_at":"2023-12-14T16:00:21.204315951+01:00","updated_at":"2023-12-14T16:00:21.204316002+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_c2c1cf5e-c7fa-4881-ae6a-1f303dc83253.json b/cmd/probo-cli/testdata.bk/exams/exam_c2c1cf5e-c7fa-4881-ae6a-1f303dc83253.json new file mode 100644 index 0000000..c219b73 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_c2c1cf5e-c7fa-4881-ae6a-1f303dc83253.json @@ -0,0 +1 @@ +{"id":"c2c1cf5e-c7fa-4881-ae6a-1f303dc83253","created_at":"2023-12-14T15:20:59.210003409+01:00","updated_at":"2023-12-14T17:45:08.913454104+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T15:20:59.208538456+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T15:20:59.209046632+01:00","hash":"","question":{"id":"6c609489-7891-40c2-a3d3-7c9c164034cb","created_at":"2023-12-14T15:20:59.209026727+01:00","updated_at":"2023-12-14T15:20:59.209026868+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T15:20:59.209095264+01:00","hash":"","question":{"id":"5013c0b9-091e-4c80-be38-967a1a0860a7","created_at":"2023-12-14T15:20:59.209084369+01:00","updated_at":"2023-12-14T15:20:59.209084439+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T15:20:59.209148651+01:00","hash":"","question":{"id":"517e8eac-8e11-4f08-bea0-92955836501e","created_at":"2023-12-14T15:20:59.209133538+01:00","updated_at":"2023-12-14T15:20:59.209133633+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},{"id":"f0c8f2ed-092a-4c75-98ba-ff35c4defa37","created_at":"2023-12-14T15:20:59.209028879+01:00","updated_at":"2023-12-14T15:20:59.209028966+01:00","text":"Giuly (❤️)"},{"id":"ca928ae9-1132-4f30-8b26-51d0e0b246a1","created_at":"2023-12-14T15:20:59.209032446+01:00","updated_at":"2023-12-14T15:20:59.209032488+01:00","text":"Jenny"},{"id":"22aaa155-7f8c-4e0f-9405-bfd050512b6b","created_at":"2023-12-14T15:20:59.209033925+01:00","updated_at":"2023-12-14T15:20:59.209033967+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"20677368-5cc3-435b-ab78-04d5fd918a06","created_at":"2023-12-14T15:20:59.209030819+01:00","updated_at":"2023-12-14T15:20:59.209030862+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_c33a1b26-f68f-4d31-9244-1074c7eab259.json b/cmd/probo-cli/testdata.bk/exams/exam_c33a1b26-f68f-4d31-9244-1074c7eab259.json new file mode 100644 index 0000000..dc574f1 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_c33a1b26-f68f-4d31-9244-1074c7eab259.json @@ -0,0 +1 @@ +{"id":"c33a1b26-f68f-4d31-9244-1074c7eab259","created_at":"2023-12-14T17:08:01.388611653+01:00","updated_at":"2023-12-14T17:45:08.913575397+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:08:01.373699046+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:08:01.373906144+01:00","hash":"","question":{"id":"1f961c2e-fc65-41e4-ae38-a18dab0b42f9","created_at":"2023-12-14T17:08:01.373883056+01:00","updated_at":"2023-12-14T17:08:01.373883179+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:08:01.373956214+01:00","hash":"","question":{"id":"217941b2-6469-4d2c-b0d1-ab9eeddea35d","created_at":"2023-12-14T17:08:01.373945394+01:00","updated_at":"2023-12-14T17:08:01.373945485+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:08:01.37400563+01:00","hash":"","question":{"id":"5bf0ff15-109b-4dd0-b539-0cab1e2d9b2c","created_at":"2023-12-14T17:08:01.37399516+01:00","updated_at":"2023-12-14T17:08:01.373995232+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},{"id":"fe60aa2c-1662-4df1-b7ab-0fcbb914cedb","created_at":"2023-12-14T17:08:01.373885292+01:00","updated_at":"2023-12-14T17:08:01.373885381+01:00","text":"Giuly (❤️)"},{"id":"e93eac2e-30a4-419d-b39c-f6f9b68b6ba4","created_at":"2023-12-14T17:08:01.373888622+01:00","updated_at":"2023-12-14T17:08:01.373888684+01:00","text":"Jenny"},{"id":"823f752f-2902-48b1-96d5-adf9141b596c","created_at":"2023-12-14T17:08:01.373890116+01:00","updated_at":"2023-12-14T17:08:01.373890157+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"87823c30-0448-4ae8-8ff0-bda5f16a91a1","created_at":"2023-12-14T17:08:01.373887107+01:00","updated_at":"2023-12-14T17:08:01.373887148+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_c8d55f76-9229-4235-a7e0-19e24be4a7eb.json b/cmd/probo-cli/testdata.bk/exams/exam_c8d55f76-9229-4235-a7e0-19e24be4a7eb.json new file mode 100644 index 0000000..0759f1c --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_c8d55f76-9229-4235-a7e0-19e24be4a7eb.json @@ -0,0 +1 @@ +{"id":"c8d55f76-9229-4235-a7e0-19e24be4a7eb","created_at":"2023-12-14T15:44:21.773098601+01:00","updated_at":"2023-12-14T17:45:08.913704191+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T15:44:21.7721619+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T15:44:21.772318358+01:00","hash":"","question":{"id":"c933a930-21f4-444a-b27f-5faf9b7949dd","created_at":"2023-12-14T15:44:21.772301163+01:00","updated_at":"2023-12-14T15:44:21.772301291+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T15:44:21.772365116+01:00","hash":"","question":{"id":"b6fb84c2-edda-46ec-a866-32b77bca39ec","created_at":"2023-12-14T15:44:21.772354384+01:00","updated_at":"2023-12-14T15:44:21.772354509+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T15:44:21.772411843+01:00","hash":"","question":{"id":"87419c3c-6c5f-4ba1-af57-039944396cb8","created_at":"2023-12-14T15:44:21.772396072+01:00","updated_at":"2023-12-14T15:44:21.772396127+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_ceedbd21-8d55-403a-bd5e-fa77578aed6f.json b/cmd/probo-cli/testdata.bk/exams/exam_ceedbd21-8d55-403a-bd5e-fa77578aed6f.json new file mode 100644 index 0000000..cd7bb5d --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_ceedbd21-8d55-403a-bd5e-fa77578aed6f.json @@ -0,0 +1 @@ +{"id":"ceedbd21-8d55-403a-bd5e-fa77578aed6f","created_at":"2023-12-14T16:59:45.618332604+01:00","updated_at":"2023-12-14T17:45:08.913827749+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:59:45.609127862+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:59:45.609331375+01:00","hash":"","question":{"id":"a462361c-ff0f-4805-ae7b-2989e61bb950","created_at":"2023-12-14T16:59:45.60932036+01:00","updated_at":"2023-12-14T16:59:45.609320462+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:59:45.609384617+01:00","hash":"","question":{"id":"3ca34fa3-adce-4cbb-b35a-650e08f280d1","created_at":"2023-12-14T16:59:45.609369708+01:00","updated_at":"2023-12-14T16:59:45.60936979+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:59:45.609284385+01:00","hash":"","question":{"id":"d6723c40-1b1e-48fa-a9ce-6198a296d89e","created_at":"2023-12-14T16:59:45.609264071+01:00","updated_at":"2023-12-14T16:59:45.609264224+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json b/cmd/probo-cli/testdata.bk/exams/exam_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json new file mode 100644 index 0000000..f35bc22 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json @@ -0,0 +1 @@ +{"id":"dba0fb9f-9843-4ab6-9cdd-0ad0312c994b","created_at":"2023-12-14T16:59:45.618020275+01:00","updated_at":"2023-12-14T17:45:08.913949208+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:59:45.608988038+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:59:45.609284385+01:00","hash":"","question":{"id":"d6723c40-1b1e-48fa-a9ce-6198a296d89e","created_at":"2023-12-14T16:59:45.609264071+01:00","updated_at":"2023-12-14T16:59:45.609264224+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:59:45.609331375+01:00","hash":"","question":{"id":"a462361c-ff0f-4805-ae7b-2989e61bb950","created_at":"2023-12-14T16:59:45.60932036+01:00","updated_at":"2023-12-14T16:59:45.609320462+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:59:45.609384617+01:00","hash":"","question":{"id":"3ca34fa3-adce-4cbb-b35a-650e08f280d1","created_at":"2023-12-14T16:59:45.609369708+01:00","updated_at":"2023-12-14T16:59:45.60936979+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},{"id":"35d11599-b2e0-444e-80d5-24b391f151d0","created_at":"2023-12-14T16:59:45.60926659+01:00","updated_at":"2023-12-14T16:59:45.609266688+01:00","text":"Giuly (❤️)"},{"id":"382bf7cc-71e7-4009-ba68-fbbe7fef5d75","created_at":"2023-12-14T16:59:45.609270125+01:00","updated_at":"2023-12-14T16:59:45.609270166+01:00","text":"Jenny"},{"id":"cf0d3f50-4c82-4f78-8c26-421621df0460","created_at":"2023-12-14T16:59:45.609271567+01:00","updated_at":"2023-12-14T16:59:45.609271609+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"ab5d4b30-8ff4-456b-9d7e-f8073672998c","created_at":"2023-12-14T16:59:45.609268534+01:00","updated_at":"2023-12-14T16:59:45.609268596+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_f45ea401-618e-4416-9ce6-0a7f0368bbbc.json b/cmd/probo-cli/testdata.bk/exams/exam_f45ea401-618e-4416-9ce6-0a7f0368bbbc.json new file mode 100644 index 0000000..72e9c67 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_f45ea401-618e-4416-9ce6-0a7f0368bbbc.json @@ -0,0 +1 @@ +{"id":"f45ea401-618e-4416-9ce6-0a7f0368bbbc","created_at":"2023-12-14T17:41:20.704090695+01:00","updated_at":"2023-12-14T17:45:08.91407083+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:41:20.694954585+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:41:20.6951014+01:00","hash":"","question":{"id":"d6177fea-44f3-4fee-9b62-e25aa538e185","created_at":"2023-12-14T17:41:20.695078549+01:00","updated_at":"2023-12-14T17:41:20.695078681+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:41:20.695148748+01:00","hash":"","question":{"id":"bd5dd43d-3fe4-4742-ada6-639d08ddc89f","created_at":"2023-12-14T17:41:20.695138077+01:00","updated_at":"2023-12-14T17:41:20.695138172+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:41:20.695198069+01:00","hash":"","question":{"id":"1aa48d1b-db29-43d5-9d35-124cfb5a529c","created_at":"2023-12-14T17:41:20.695183093+01:00","updated_at":"2023-12-14T17:41:20.69518316+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},{"id":"d57042c1-50b2-43d3-9ad2-c0843acfd89b","created_at":"2023-12-14T17:41:20.695080976+01:00","updated_at":"2023-12-14T17:41:20.695081064+01:00","text":"Giuly (❤️)"},{"id":"d98fee39-70a4-48ad-a3be-fe5001d6276a","created_at":"2023-12-14T17:41:20.695085174+01:00","updated_at":"2023-12-14T17:41:20.695085216+01:00","text":"Jenny"},{"id":"b1c01beb-8999-4f70-bae8-343df6587df1","created_at":"2023-12-14T17:41:20.695086661+01:00","updated_at":"2023-12-14T17:41:20.695086703+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"5409cfad-3543-4efd-9c33-020c3b25126a","created_at":"2023-12-14T17:41:20.695083519+01:00","updated_at":"2023-12-14T17:41:20.695083582+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_f7590083-21f9-41d3-baf6-9bc8d1bf93cb.json b/cmd/probo-cli/testdata.bk/exams/exam_f7590083-21f9-41d3-baf6-9bc8d1bf93cb.json new file mode 100644 index 0000000..40fe3b1 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_f7590083-21f9-41d3-baf6-9bc8d1bf93cb.json @@ -0,0 +1 @@ +{"id":"f7590083-21f9-41d3-baf6-9bc8d1bf93cb","created_at":"2023-12-14T15:44:21.773167301+01:00","updated_at":"2023-12-14T17:45:08.914202584+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T15:44:21.772042788+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T15:44:21.772318358+01:00","hash":"","question":{"id":"c933a930-21f4-444a-b27f-5faf9b7949dd","created_at":"2023-12-14T15:44:21.772301163+01:00","updated_at":"2023-12-14T15:44:21.772301291+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T15:44:21.772365116+01:00","hash":"","question":{"id":"b6fb84c2-edda-46ec-a866-32b77bca39ec","created_at":"2023-12-14T15:44:21.772354384+01:00","updated_at":"2023-12-14T15:44:21.772354509+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T15:44:21.772411843+01:00","hash":"","question":{"id":"87419c3c-6c5f-4ba1-af57-039944396cb8","created_at":"2023-12-14T15:44:21.772396072+01:00","updated_at":"2023-12-14T15:44:21.772396127+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},{"id":"6311b548-cbf6-40b4-bfae-be480a8da522","created_at":"2023-12-14T15:44:21.772303748+01:00","updated_at":"2023-12-14T15:44:21.77230384+01:00","text":"Giuly (❤️)"},{"id":"0e4e0ba9-b957-43bd-abd2-8f0f7c45d936","created_at":"2023-12-14T15:44:21.772307168+01:00","updated_at":"2023-12-14T15:44:21.772307223+01:00","text":"Jenny"},{"id":"5f2532bb-db1a-457f-82f2-209d486b506c","created_at":"2023-12-14T15:44:21.77230881+01:00","updated_at":"2023-12-14T15:44:21.772308875+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"69ce0a06-2cf6-4dc3-a954-12b76d6bb09d","created_at":"2023-12-14T15:44:21.772305446+01:00","updated_at":"2023-12-14T15:44:21.772305489+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_faa8b2ee-2cc1-4a41-be39-df88282554f2.json b/cmd/probo-cli/testdata.bk/exams/exam_faa8b2ee-2cc1-4a41-be39-df88282554f2.json new file mode 100644 index 0000000..74d66b2 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_faa8b2ee-2cc1-4a41-be39-df88282554f2.json @@ -0,0 +1 @@ +{"id":"faa8b2ee-2cc1-4a41-be39-df88282554f2","created_at":"2023-12-14T17:01:05.115140297+01:00","updated_at":"2023-12-14T17:45:08.914321136+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:01:05.107766575+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:01:05.108222326+01:00","hash":"","question":{"id":"c20974ac-b6e5-4a14-8bc5-2556af7b3ca4","created_at":"2023-12-14T17:01:05.108206845+01:00","updated_at":"2023-12-14T17:01:05.10820691+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:01:05.107915761+01:00","hash":"","question":{"id":"13152027-08e7-4ea9-b055-8fa9b03b67e5","created_at":"2023-12-14T17:01:05.107895756+01:00","updated_at":"2023-12-14T17:01:05.107895888+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:01:05.107962826+01:00","hash":"","question":{"id":"9f9a5537-edbf-443f-b234-bd6d61293f4e","created_at":"2023-12-14T17:01:05.107951975+01:00","updated_at":"2023-12-14T17:01:05.107952042+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},{"id":"2f03462f-349e-414a-b21c-d6e5ed7a9a34","created_at":"2023-12-14T17:01:05.107901771+01:00","updated_at":"2023-12-14T17:01:05.107901812+01:00","text":"Jenny"},{"id":"e87d512b-af76-49e3-9208-8c728474f482","created_at":"2023-12-14T17:01:05.107898313+01:00","updated_at":"2023-12-14T17:01:05.107898406+01:00","text":"Giuly (❤️)"},{"id":"1ecc1994-d82f-47c9-ba1a-4b65d741675d","created_at":"2023-12-14T17:01:05.10790328+01:00","updated_at":"2023-12-14T17:01:05.107903321+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"d098163d-0e64-41bc-8c0c-d53b5fddf7be","created_at":"2023-12-14T17:01:05.107900146+01:00","updated_at":"2023-12-14T17:01:05.107900197+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_fb2fcb6b-f5b2-4176-9c9c-b75fb0352320.json b/cmd/probo-cli/testdata.bk/exams/exam_fb2fcb6b-f5b2-4176-9c9c-b75fb0352320.json new file mode 100644 index 0000000..72ea061 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_fb2fcb6b-f5b2-4176-9c9c-b75fb0352320.json @@ -0,0 +1 @@ +{"id":"fb2fcb6b-f5b2-4176-9c9c-b75fb0352320","created_at":"2023-12-14T17:07:52.036070779+01:00","updated_at":"2023-12-14T17:45:08.914439529+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:07:52.025748963+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T17:07:52.025956869+01:00","hash":"","question":{"id":"d886140d-76bc-4225-94bf-6c5eb597c561","created_at":"2023-12-14T17:07:52.025923438+01:00","updated_at":"2023-12-14T17:07:52.025923609+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T17:07:52.026034589+01:00","hash":"","question":{"id":"3cd661fd-2c01-49af-b8e8-38b1cc9823a4","created_at":"2023-12-14T17:07:52.026014854+01:00","updated_at":"2023-12-14T17:07:52.026014982+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T17:07:52.026117153+01:00","hash":"","question":{"id":"628e2604-88dd-4748-b927-002bf26cd745","created_at":"2023-12-14T17:07:52.026093354+01:00","updated_at":"2023-12-14T17:07:52.026093447+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},{"id":"0bcc578a-dc5b-46f3-a0e0-1c6038b0a656","created_at":"2023-12-14T17:07:52.02592712+01:00","updated_at":"2023-12-14T17:07:52.025927253+01:00","text":"Giuly (❤️)"},{"id":"9eb83d45-aef2-456c-9cb8-3a19f17da5d8","created_at":"2023-12-14T17:07:52.025933023+01:00","updated_at":"2023-12-14T17:07:52.025933083+01:00","text":"Jenny"},{"id":"a01843e5-4402-4850-bd44-62798bf692e4","created_at":"2023-12-14T17:07:52.025935694+01:00","updated_at":"2023-12-14T17:07:52.02593575+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"b56b1fec-cc8a-4422-8690-b4a15880bedb","created_at":"2023-12-14T17:07:52.02593021+01:00","updated_at":"2023-12-14T17:07:52.025930278+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/exams/exam_fd7a5639-d764-42eb-a2e5-b69702fc2a77.json b/cmd/probo-cli/testdata.bk/exams/exam_fd7a5639-d764-42eb-a2e5-b69702fc2a77.json new file mode 100644 index 0000000..85c8aca --- /dev/null +++ b/cmd/probo-cli/testdata.bk/exams/exam_fd7a5639-d764-42eb-a2e5-b69702fc2a77.json @@ -0,0 +1 @@ +{"id":"fd7a5639-d764-42eb-a2e5-b69702fc2a77","created_at":"2023-12-14T16:58:58.791446947+01:00","updated_at":"2023-12-14T17:45:08.914563437+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T16:58:58.789573663+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"908bb025-6370-4273-8448-8470f9336f26","created_at":"2023-12-05T21:22:06.322398595+01:00","updated_at":"2023-12-14T16:58:58.789870342+01:00","hash":"","question":{"id":"bb436e89-ecfd-4422-a109-84cf22491f3f","created_at":"2023-12-14T16:58:58.789851155+01:00","updated_at":"2023-12-14T16:58:58.789851302+01:00","text":"Chi è l'#amore più grande della mia vita?"},"answers":[{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},"CorrectPos":0,"type":0},{"id":"6e989533-276c-45d5-9048-24a575289ed9","created_at":"2023-12-12T09:25:01.783698764+01:00","updated_at":"2023-12-14T16:58:58.789917613+01:00","hash":"","question":{"id":"4d8796d3-f2d4-4ded-abb1-feeb7a36b1ab","created_at":"2023-12-14T16:58:58.789906814+01:00","updated_at":"2023-12-14T16:58:58.789906939+01:00","text":"Chi è la ragazza più meravigliosa del mondo?"},"answers":[{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},"CorrectPos":0,"type":0},{"id":"41c2a4a8-04b3-42c2-bbb7-10b8908fcf36","created_at":"2023-12-12T09:25:01.783808508+01:00","updated_at":"2023-12-14T16:58:58.7899646+01:00","hash":"","question":{"id":"6d0a3106-2878-488a-9e07-bb99213b6c39","created_at":"2023-12-14T16:58:58.789948487+01:00","updated_at":"2023-12-14T16:58:58.789948551+01:00","text":"Chi è la donna più affascinante dell'Universo?"},"answers":[{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},{"id":"62c4c770-866e-4dc8-8b2d-c8739d4d36f2","created_at":"2023-12-14T16:58:58.789853697+01:00","updated_at":"2023-12-14T16:58:58.789853789+01:00","text":"Giuly (❤️)"},{"id":"f569fff8-1e66-4830-9cc6-ef83926b65b4","created_at":"2023-12-14T16:58:58.789857016+01:00","updated_at":"2023-12-14T16:58:58.789857058+01:00","text":"Jenny"},{"id":"8abc4d7f-8860-4481-b336-f62e788d64f4","created_at":"2023-12-14T16:58:58.789858548+01:00","updated_at":"2023-12-14T16:58:58.789858588+01:00","text":"Lilly"}],"tags":[],"correct":{"id":"7699a17e-5899-400f-858d-53ba3a18dc3e","created_at":"2023-12-14T16:58:58.789855491+01:00","updated_at":"2023-12-14T16:58:58.789855554+01:00","text":"Daisy"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/participants/andrea.json b/cmd/probo-cli/testdata.bk/participants/andrea.json new file mode 100644 index 0000000..20af4e2 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/participants/andrea.json @@ -0,0 +1 @@ +{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:45:08.904532708+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/participants/participant.json b/cmd/probo-cli/testdata.bk/participants/participant.json new file mode 100644 index 0000000..f205136 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/participants/participant.json @@ -0,0 +1 @@ +{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-14T17:45:08.904646212+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata.bk/quizzes/quiz_1.md b/cmd/probo-cli/testdata.bk/quizzes/quiz_1.md new file mode 100644 index 0000000..8c788a9 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/quizzes/quiz_1.md @@ -0,0 +1,11 @@ +--- +id: 908bb025-6370-4273-8448-8470f9336f26 +created_at: 2023-12-05T21:22:06.322398595+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Chi è l'#amore più grande della mia vita? + +* Giuly (❤️) +* Daisy +* Jenny +* Lilly diff --git a/cmd/probo-cli/testdata.bk/quizzes/quiz_2.md b/cmd/probo-cli/testdata.bk/quizzes/quiz_2.md new file mode 100644 index 0000000..bc5e0ed --- /dev/null +++ b/cmd/probo-cli/testdata.bk/quizzes/quiz_2.md @@ -0,0 +1,11 @@ +--- +id: 6e989533-276c-45d5-9048-24a575289ed9 +created_at: 2023-12-12T09:25:01.783698764+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Chi è la ragazza più meravigliosa del mondo? + +* Daisy +* Jenny +* Giuly (❤️) +* Lilly diff --git a/cmd/probo-cli/testdata.bk/quizzes/quiz_3.md b/cmd/probo-cli/testdata.bk/quizzes/quiz_3.md new file mode 100644 index 0000000..bb1ea16 --- /dev/null +++ b/cmd/probo-cli/testdata.bk/quizzes/quiz_3.md @@ -0,0 +1,11 @@ +--- +id: 41c2a4a8-04b3-42c2-bbb7-10b8908fcf36 +created_at: 2023-12-12T09:25:01.783808508+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Chi è la donna più affascinante dell'Universo? + +* Daisy +* Giuly (❤️) +* Jenny +* Lilly diff --git a/cmd/probo-cli/testdata.bk/responses/response_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json b/cmd/probo-cli/testdata.bk/responses/response_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json new file mode 100644 index 0000000..c92706c --- /dev/null +++ b/cmd/probo-cli/testdata.bk/responses/response_dba0fb9f-9843-4ab6-9cdd-0ad0312c994b.json @@ -0,0 +1 @@ +{"id":"dba0fb9f-9843-4ab6-9cdd-0ad0312c994b","created_at":"2023-12-14T17:43:49.440956408+01:00","updated_at":"2023-12-14T17:45:08.916225135+01:00","Questions":{"3ca34fa3-adce-4cbb-b35a-650e08f280d1":"35d11599-b2e0-444e-80d5-24b391f151d0","a462361c-ff0f-4805-ae7b-2989e61bb950":"35d11599-b2e0-444e-80d5-24b391f151d0","d6723c40-1b1e-48fa-a9ce-6198a296d89e":"35d11599-b2e0-444e-80d5-24b391f151d0"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json b/cmd/probo-cli/testdata/exams/exam_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json new file mode 100644 index 0000000..f266425 --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json @@ -0,0 +1 @@ +{"id":"0c3393eb-34c1-487b-b0c5-ad2df2ea91b6","created_at":"2023-12-17T18:18:29.155046395+01:00","updated_at":"2023-12-17T18:48:05.375103973+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:18:29.154447458+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:18:29.154733234+01:00","hash":"","question":{"id":"4ad789b0-cf77-42cd-bce6-d81d52113c01","created_at":"2023-12-17T18:18:29.154713359+01:00","updated_at":"2023-12-17T18:18:29.154713469+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"8c9b57b2-2f84-4da7-b3e4-217e5b5902aa","created_at":"2023-12-17T18:18:29.154717796+01:00","updated_at":"2023-12-17T18:18:29.154717836+01:00","text":"3"},{"id":"74bf51a1-ce46-4360-a2a6-7b19983181db","created_at":"2023-12-17T18:18:29.154719331+01:00","updated_at":"2023-12-17T18:18:29.154719394+01:00","text":"4"},{"id":"2d0d2f0f-48b6-4aab-aa1d-5caa99d5b11f","created_at":"2023-12-17T18:18:29.154720823+01:00","updated_at":"2023-12-17T18:18:29.154720864+01:00","text":"0"}],"tags":[],"correct":{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},"CorrectPos":0,"type":0},{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:18:29.154780203+01:00","hash":"","question":{"id":"1ff08b57-dac7-4ab4-9874-a351e69b5395","created_at":"2023-12-17T18:18:29.154768352+01:00","updated_at":"2023-12-17T18:18:29.154768427+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},{"id":"8f643ed0-c6da-460c-a620-7abacbec54e7","created_at":"2023-12-17T18:18:29.154771507+01:00","updated_at":"2023-12-17T18:18:29.154771548+01:00","text":"7"},{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"a3754b2a-e94a-4065-87d9-443a593106c0","created_at":"2023-12-17T18:18:29.154773883+01:00","updated_at":"2023-12-17T18:18:29.154773925+01:00","text":"1"}],"tags":[],"correct":{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:18:29.154835367+01:00","hash":"","question":{"id":"cbc95a46-e728-49b5-b865-9645f8859ae3","created_at":"2023-12-17T18:18:29.154814412+01:00","updated_at":"2023-12-17T18:18:29.154814466+01:00","text":"Un campo elettrico"},"answers":[{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},{"id":"19b026fd-0a7e-4894-8c75-d7c8a3bdae18","created_at":"2023-12-17T18:18:29.154818196+01:00","updated_at":"2023-12-17T18:18:29.154818239+01:00","text":"E' un campo di forze non conservative"},{"id":"c44d2c2f-385a-468e-8357-43cecf314231","created_at":"2023-12-17T18:18:29.154820248+01:00","updated_at":"2023-12-17T18:18:29.154820288+01:00","text":"E' un campo di grano"},{"id":"817e4b82-63ee-4bb0-be10-9d7dbdeeb704","created_at":"2023-12-17T18:18:29.154827893+01:00","updated_at":"2023-12-17T18:18:29.154827934+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_35654b75-e874-45ba-8c3e-ba55a7d6fc2a.json b/cmd/probo-cli/testdata/exams/exam_35654b75-e874-45ba-8c3e-ba55a7d6fc2a.json new file mode 100644 index 0000000..2e4c325 --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_35654b75-e874-45ba-8c3e-ba55a7d6fc2a.json @@ -0,0 +1 @@ +{"id":"35654b75-e874-45ba-8c3e-ba55a7d6fc2a","created_at":"2023-12-17T18:19:00.54572983+01:00","updated_at":"2023-12-17T18:48:05.375285781+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:19:00.539634834+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:19:00.539872007+01:00","hash":"","question":{"id":"6e0d22be-078b-49f0-b1ee-0df7af7762a9","created_at":"2023-12-17T18:19:00.539851684+01:00","updated_at":"2023-12-17T18:19:00.539851725+01:00","text":"Un campo elettrico"},"answers":[{"id":"3f3aa6d5-e0fc-448a-af05-872459116b21","created_at":"2023-12-17T18:19:00.539853389+01:00","updated_at":"2023-12-17T18:19:00.539853433+01:00","text":"E' un campo di forse conservative"},{"id":"8cf91753-9ee6-4283-8148-79dabe7710cb","created_at":"2023-12-17T18:19:00.539855684+01:00","updated_at":"2023-12-17T18:19:00.539855727+01:00","text":"E' un campo di forze non conservative"},{"id":"f043027b-a548-4bf8-b191-c5becb90706c","created_at":"2023-12-17T18:19:00.539857688+01:00","updated_at":"2023-12-17T18:19:00.53985773+01:00","text":"E' un campo di grano"},{"id":"99374332-7294-4cb5-b123-93df16b83f55","created_at":"2023-12-17T18:19:00.53986442+01:00","updated_at":"2023-12-17T18:19:00.539864461+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"3f3aa6d5-e0fc-448a-af05-872459116b21","created_at":"2023-12-17T18:19:00.539853389+01:00","updated_at":"2023-12-17T18:19:00.539853433+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0},{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:19:00.539770657+01:00","hash":"","question":{"id":"4dab51f0-42c0-4ce3-a85f-457ea17a1858","created_at":"2023-12-17T18:19:00.539751762+01:00","updated_at":"2023-12-17T18:19:00.539751874+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"2ef783a7-6ec9-46cb-a265-92631d47b804","created_at":"2023-12-17T18:19:00.539754148+01:00","updated_at":"2023-12-17T18:19:00.539754242+01:00","text":"2"},{"id":"64cff1d3-5055-447c-baec-68c00c89e421","created_at":"2023-12-17T18:19:00.539755895+01:00","updated_at":"2023-12-17T18:19:00.539755938+01:00","text":"3"},{"id":"c932d84d-43e8-449a-bf5c-e998405de178","created_at":"2023-12-17T18:19:00.539757483+01:00","updated_at":"2023-12-17T18:19:00.539757546+01:00","text":"4"},{"id":"85d9cdf8-c905-443f-b4a7-f80477a2192e","created_at":"2023-12-17T18:19:00.539759122+01:00","updated_at":"2023-12-17T18:19:00.539759164+01:00","text":"0"}],"tags":[],"correct":{"id":"2ef783a7-6ec9-46cb-a265-92631d47b804","created_at":"2023-12-17T18:19:00.539754148+01:00","updated_at":"2023-12-17T18:19:00.539754242+01:00","text":"2"},"CorrectPos":0,"type":0},{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:19:00.539821012+01:00","hash":"","question":{"id":"8bed8b76-9a40-49ea-a9e2-ca7da3672d4d","created_at":"2023-12-17T18:19:00.539808879+01:00","updated_at":"2023-12-17T18:19:00.539808974+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"e42c04ed-52dd-4093-84a6-333bd5600e43","created_at":"2023-12-17T18:19:00.539810539+01:00","updated_at":"2023-12-17T18:19:00.539810585+01:00","text":"9"},{"id":"341f1b4a-423a-4f5e-9c4f-80333c0048f4","created_at":"2023-12-17T18:19:00.539812057+01:00","updated_at":"2023-12-17T18:19:00.539812098+01:00","text":"7"},{"id":"2ef783a7-6ec9-46cb-a265-92631d47b804","created_at":"2023-12-17T18:19:00.539754148+01:00","updated_at":"2023-12-17T18:19:00.539754242+01:00","text":"2"},{"id":"432bd3a1-2a8d-4500-98d1-7ede69db837e","created_at":"2023-12-17T18:19:00.539814541+01:00","updated_at":"2023-12-17T18:19:00.539814583+01:00","text":"1"}],"tags":[],"correct":{"id":"e42c04ed-52dd-4093-84a6-333bd5600e43","created_at":"2023-12-17T18:19:00.539810539+01:00","updated_at":"2023-12-17T18:19:00.539810585+01:00","text":"9"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_53e25b31-c050-4cf8-8f7a-db46934d9bd6.json b/cmd/probo-cli/testdata/exams/exam_53e25b31-c050-4cf8-8f7a-db46934d9bd6.json new file mode 100644 index 0000000..71122c3 --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_53e25b31-c050-4cf8-8f7a-db46934d9bd6.json @@ -0,0 +1 @@ +{"id":"53e25b31-c050-4cf8-8f7a-db46934d9bd6","created_at":"2023-12-17T18:18:36.988865241+01:00","updated_at":"2023-12-17T18:48:05.375526078+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:18:36.98251639+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:18:36.98264872+01:00","hash":"","question":{"id":"51641d98-bb19-4535-969e-f4f45eb2c396","created_at":"2023-12-17T18:18:36.982633423+01:00","updated_at":"2023-12-17T18:18:36.982633536+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"7ec5dacd-7141-4b4b-b8eb-0421ca8baa26","created_at":"2023-12-17T18:18:36.982635742+01:00","updated_at":"2023-12-17T18:18:36.982635833+01:00","text":"2"},{"id":"02b73542-5803-4072-b26d-773db52f16f4","created_at":"2023-12-17T18:18:36.982637386+01:00","updated_at":"2023-12-17T18:18:36.982637427+01:00","text":"3"},{"id":"8c813baf-71d0-43f8-adc8-2cd4ce5b41ff","created_at":"2023-12-17T18:18:36.982639837+01:00","updated_at":"2023-12-17T18:18:36.982639897+01:00","text":"4"},{"id":"1a200785-4921-4ddf-860e-130a1f771eaa","created_at":"2023-12-17T18:18:36.982641451+01:00","updated_at":"2023-12-17T18:18:36.982641494+01:00","text":"0"}],"tags":[],"correct":{"id":"7ec5dacd-7141-4b4b-b8eb-0421ca8baa26","created_at":"2023-12-17T18:18:36.982635742+01:00","updated_at":"2023-12-17T18:18:36.982635833+01:00","text":"2"},"CorrectPos":0,"type":0},{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:18:36.982703357+01:00","hash":"","question":{"id":"7c5f85e2-195a-4f51-9015-ad4c5353b1b4","created_at":"2023-12-17T18:18:36.982691299+01:00","updated_at":"2023-12-17T18:18:36.98269139+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"215ebe7f-622c-4420-b12c-0c3f17af400a","created_at":"2023-12-17T18:18:36.982692907+01:00","updated_at":"2023-12-17T18:18:36.982692962+01:00","text":"9"},{"id":"e062b523-c9e8-4924-b78d-a5ff19624a58","created_at":"2023-12-17T18:18:36.982694503+01:00","updated_at":"2023-12-17T18:18:36.982694545+01:00","text":"7"},{"id":"7ec5dacd-7141-4b4b-b8eb-0421ca8baa26","created_at":"2023-12-17T18:18:36.982635742+01:00","updated_at":"2023-12-17T18:18:36.982635833+01:00","text":"2"},{"id":"29fbf2d3-4d52-4fbe-a4dc-a7dc0ae29c35","created_at":"2023-12-17T18:18:36.982696936+01:00","updated_at":"2023-12-17T18:18:36.982696978+01:00","text":"1"}],"tags":[],"correct":{"id":"215ebe7f-622c-4420-b12c-0c3f17af400a","created_at":"2023-12-17T18:18:36.982692907+01:00","updated_at":"2023-12-17T18:18:36.982692962+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:18:36.98304965+01:00","hash":"","question":{"id":"8ff51e9f-cf04-489b-bfa2-074cbc353527","created_at":"2023-12-17T18:18:36.982735002+01:00","updated_at":"2023-12-17T18:18:36.982735065+01:00","text":"Un campo elettrico"},"answers":[{"id":"7a3f7b78-873f-401b-a562-a000aa81279a","created_at":"2023-12-17T18:18:36.983035324+01:00","updated_at":"2023-12-17T18:18:36.983035381+01:00","text":"E' un campo di forse conservative"},{"id":"0f8034f9-3c8a-400c-bfbc-49a18d7243bb","created_at":"2023-12-17T18:18:36.983038064+01:00","updated_at":"2023-12-17T18:18:36.983038105+01:00","text":"E' un campo di forze non conservative"},{"id":"5550926f-ab42-4a65-9767-9bc4e2e06e9c","created_at":"2023-12-17T18:18:36.983040418+01:00","updated_at":"2023-12-17T18:18:36.983040459+01:00","text":"E' un campo di grano"},{"id":"ce3bb729-918e-461f-9fa4-944d07e1bdea","created_at":"2023-12-17T18:18:36.98304202+01:00","updated_at":"2023-12-17T18:18:36.983042061+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"7a3f7b78-873f-401b-a562-a000aa81279a","created_at":"2023-12-17T18:18:36.983035324+01:00","updated_at":"2023-12-17T18:18:36.983035381+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_66079641-c419-4ee7-b16f-d960167dd8ac.json b/cmd/probo-cli/testdata/exams/exam_66079641-c419-4ee7-b16f-d960167dd8ac.json new file mode 100644 index 0000000..d160588 --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_66079641-c419-4ee7-b16f-d960167dd8ac.json @@ -0,0 +1 @@ +{"id":"66079641-c419-4ee7-b16f-d960167dd8ac","created_at":"2023-12-17T18:27:53.512942058+01:00","updated_at":"2023-12-17T18:48:05.375743594+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:27:53.511813048+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:27:53.512062885+01:00","hash":"","question":{"id":"965d6855-5cdd-41bd-b9b7-3c4abe7a75f8","created_at":"2023-12-17T18:27:53.512050564+01:00","updated_at":"2023-12-17T18:27:53.512050651+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"f87ce198-41cf-49da-8bc7-f2d75d514446","created_at":"2023-12-17T18:27:53.512052219+01:00","updated_at":"2023-12-17T18:27:53.512052265+01:00","text":"9"},{"id":"0fea4e4a-595b-406f-80ab-6ba835ff0059","created_at":"2023-12-17T18:27:53.512053702+01:00","updated_at":"2023-12-17T18:27:53.512053743+01:00","text":"7"},{"id":"81cc6109-591d-4d3c-9c4f-ed9c2f30e5ea","created_at":"2023-12-17T18:27:53.511995586+01:00","updated_at":"2023-12-17T18:27:53.51199568+01:00","text":"2"},{"id":"115054bd-d7fc-4b33-ab9b-915b961a92e4","created_at":"2023-12-17T18:27:53.512056212+01:00","updated_at":"2023-12-17T18:27:53.512056254+01:00","text":"1"}],"tags":[],"correct":{"id":"f87ce198-41cf-49da-8bc7-f2d75d514446","created_at":"2023-12-17T18:27:53.512052219+01:00","updated_at":"2023-12-17T18:27:53.512052265+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:27:53.512114752+01:00","hash":"","question":{"id":"5843a08b-6cda-4290-9895-4ce5dccdc6f4","created_at":"2023-12-17T18:27:53.512093807+01:00","updated_at":"2023-12-17T18:27:53.512093851+01:00","text":"Un campo elettrico"},"answers":[{"id":"ca558587-ec5a-4978-a041-9270fd2cc3d9","created_at":"2023-12-17T18:27:53.512101352+01:00","updated_at":"2023-12-17T18:27:53.51210141+01:00","text":"E' un campo di forse conservative"},{"id":"24dd858f-0ce5-495d-bd1f-5de64fda7c4b","created_at":"2023-12-17T18:27:53.512103728+01:00","updated_at":"2023-12-17T18:27:53.51210377+01:00","text":"E' un campo di forze non conservative"},{"id":"a900ed4c-3ba7-4a38-af89-53989b0c8628","created_at":"2023-12-17T18:27:53.512105675+01:00","updated_at":"2023-12-17T18:27:53.512105716+01:00","text":"E' un campo di grano"},{"id":"ce8416b2-b67a-4dd9-8b18-932cbd7d709e","created_at":"2023-12-17T18:27:53.512107196+01:00","updated_at":"2023-12-17T18:27:53.512107239+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"ca558587-ec5a-4978-a041-9270fd2cc3d9","created_at":"2023-12-17T18:27:53.512101352+01:00","updated_at":"2023-12-17T18:27:53.51210141+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0},{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:27:53.512009176+01:00","hash":"","question":{"id":"b9c49cc5-956a-4f10-aeca-75dec2e9183a","created_at":"2023-12-17T18:27:53.511993267+01:00","updated_at":"2023-12-17T18:27:53.511993386+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"81cc6109-591d-4d3c-9c4f-ed9c2f30e5ea","created_at":"2023-12-17T18:27:53.511995586+01:00","updated_at":"2023-12-17T18:27:53.51199568+01:00","text":"2"},{"id":"2216d2f6-1210-497b-af73-cc1f3cb383f4","created_at":"2023-12-17T18:27:53.511997239+01:00","updated_at":"2023-12-17T18:27:53.511997301+01:00","text":"3"},{"id":"bba861be-0bd3-455d-ba82-7ccc77c2bcce","created_at":"2023-12-17T18:27:53.511999764+01:00","updated_at":"2023-12-17T18:27:53.511999806+01:00","text":"4"},{"id":"da0f509d-e1a4-498b-88eb-8a29862cca76","created_at":"2023-12-17T18:27:53.512001517+01:00","updated_at":"2023-12-17T18:27:53.512001559+01:00","text":"0"}],"tags":[],"correct":{"id":"81cc6109-591d-4d3c-9c4f-ed9c2f30e5ea","created_at":"2023-12-17T18:27:53.511995586+01:00","updated_at":"2023-12-17T18:27:53.51199568+01:00","text":"2"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_a0a419aa-31a8-4add-8a39-33a8cb0be381.json b/cmd/probo-cli/testdata/exams/exam_a0a419aa-31a8-4add-8a39-33a8cb0be381.json new file mode 100644 index 0000000..d95b5ee --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_a0a419aa-31a8-4add-8a39-33a8cb0be381.json @@ -0,0 +1 @@ +{"id":"a0a419aa-31a8-4add-8a39-33a8cb0be381","created_at":"2023-12-17T18:18:29.154872907+01:00","updated_at":"2023-12-17T18:48:05.375972463+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:18:29.154592726+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:18:29.154780203+01:00","hash":"","question":{"id":"1ff08b57-dac7-4ab4-9874-a351e69b5395","created_at":"2023-12-17T18:18:29.154768352+01:00","updated_at":"2023-12-17T18:18:29.154768427+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},{"id":"8f643ed0-c6da-460c-a620-7abacbec54e7","created_at":"2023-12-17T18:18:29.154771507+01:00","updated_at":"2023-12-17T18:18:29.154771548+01:00","text":"7"},{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"a3754b2a-e94a-4065-87d9-443a593106c0","created_at":"2023-12-17T18:18:29.154773883+01:00","updated_at":"2023-12-17T18:18:29.154773925+01:00","text":"1"}],"tags":[],"correct":{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:18:29.154835367+01:00","hash":"","question":{"id":"cbc95a46-e728-49b5-b865-9645f8859ae3","created_at":"2023-12-17T18:18:29.154814412+01:00","updated_at":"2023-12-17T18:18:29.154814466+01:00","text":"Un campo elettrico"},"answers":[{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},{"id":"19b026fd-0a7e-4894-8c75-d7c8a3bdae18","created_at":"2023-12-17T18:18:29.154818196+01:00","updated_at":"2023-12-17T18:18:29.154818239+01:00","text":"E' un campo di forze non conservative"},{"id":"c44d2c2f-385a-468e-8357-43cecf314231","created_at":"2023-12-17T18:18:29.154820248+01:00","updated_at":"2023-12-17T18:18:29.154820288+01:00","text":"E' un campo di grano"},{"id":"817e4b82-63ee-4bb0-be10-9d7dbdeeb704","created_at":"2023-12-17T18:18:29.154827893+01:00","updated_at":"2023-12-17T18:18:29.154827934+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0},{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:18:29.154733234+01:00","hash":"","question":{"id":"4ad789b0-cf77-42cd-bce6-d81d52113c01","created_at":"2023-12-17T18:18:29.154713359+01:00","updated_at":"2023-12-17T18:18:29.154713469+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"8c9b57b2-2f84-4da7-b3e4-217e5b5902aa","created_at":"2023-12-17T18:18:29.154717796+01:00","updated_at":"2023-12-17T18:18:29.154717836+01:00","text":"3"},{"id":"74bf51a1-ce46-4360-a2a6-7b19983181db","created_at":"2023-12-17T18:18:29.154719331+01:00","updated_at":"2023-12-17T18:18:29.154719394+01:00","text":"4"},{"id":"2d0d2f0f-48b6-4aab-aa1d-5caa99d5b11f","created_at":"2023-12-17T18:18:29.154720823+01:00","updated_at":"2023-12-17T18:18:29.154720864+01:00","text":"0"}],"tags":[],"correct":{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/exams/exam_ccd199ae-2ff9-4bc0-9b7a-045010e0e564.json b/cmd/probo-cli/testdata/exams/exam_ccd199ae-2ff9-4bc0-9b7a-045010e0e564.json new file mode 100644 index 0000000..33d80d1 --- /dev/null +++ b/cmd/probo-cli/testdata/exams/exam_ccd199ae-2ff9-4bc0-9b7a-045010e0e564.json @@ -0,0 +1 @@ +{"id":"ccd199ae-2ff9-4bc0-9b7a-045010e0e564","created_at":"2023-12-17T18:25:29.841264526+01:00","updated_at":"2023-12-17T18:48:05.376143954+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:25:29.840244096+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:25:29.840551625+01:00","hash":"","question":{"id":"64f8a880-3368-455e-bd8b-3b199b670bb8","created_at":"2023-12-17T18:25:29.840530747+01:00","updated_at":"2023-12-17T18:25:29.840530832+01:00","text":"Un campo elettrico"},"answers":[{"id":"291fd1d1-60e9-4449-81c4-d84c58b9e45b","created_at":"2023-12-17T18:25:29.840538171+01:00","updated_at":"2023-12-17T18:25:29.840538227+01:00","text":"E' un campo di forse conservative"},{"id":"580ece28-f8b7-413e-bffd-306b0055c2f2","created_at":"2023-12-17T18:25:29.840540643+01:00","updated_at":"2023-12-17T18:25:29.840540683+01:00","text":"E' un campo di forze non conservative"},{"id":"9a4efe84-c732-4c9d-8507-2a806c2c3a3d","created_at":"2023-12-17T18:25:29.840542735+01:00","updated_at":"2023-12-17T18:25:29.840542776+01:00","text":"E' un campo di grano"},{"id":"9b03925b-707c-4ea7-88b4-0d0563b425a7","created_at":"2023-12-17T18:25:29.840544256+01:00","updated_at":"2023-12-17T18:25:29.840544297+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"291fd1d1-60e9-4449-81c4-d84c58b9e45b","created_at":"2023-12-17T18:25:29.840538171+01:00","updated_at":"2023-12-17T18:25:29.840538227+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0},{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:25:29.840444808+01:00","hash":"","question":{"id":"43ae3f68-ab2d-408d-80b9-c2f1a5b39404","created_at":"2023-12-17T18:25:29.84042866+01:00","updated_at":"2023-12-17T18:25:29.840428785+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"cd9ed4bf-2d64-4da9-823a-626d935e30a0","created_at":"2023-12-17T18:25:29.840431459+01:00","updated_at":"2023-12-17T18:25:29.840431554+01:00","text":"2"},{"id":"974a4e5b-b738-409e-b208-756f64ef8aae","created_at":"2023-12-17T18:25:29.840433257+01:00","updated_at":"2023-12-17T18:25:29.840433299+01:00","text":"3"},{"id":"8d4e7d8a-a8c7-4ebe-a6a7-1cff73294274","created_at":"2023-12-17T18:25:29.840435713+01:00","updated_at":"2023-12-17T18:25:29.840435771+01:00","text":"4"},{"id":"eab1d3cd-32a1-430b-a47b-63c892bf0aff","created_at":"2023-12-17T18:25:29.840437296+01:00","updated_at":"2023-12-17T18:25:29.840437338+01:00","text":"0"}],"tags":[],"correct":{"id":"cd9ed4bf-2d64-4da9-823a-626d935e30a0","created_at":"2023-12-17T18:25:29.840431459+01:00","updated_at":"2023-12-17T18:25:29.840431554+01:00","text":"2"},"CorrectPos":0,"type":0},{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:25:29.84049888+01:00","hash":"","question":{"id":"c519651e-47da-470b-930d-f42dc5717582","created_at":"2023-12-17T18:25:29.840486893+01:00","updated_at":"2023-12-17T18:25:29.840487011+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"6b5f9986-975f-408e-b0b6-ed224e920dc6","created_at":"2023-12-17T18:25:29.840488541+01:00","updated_at":"2023-12-17T18:25:29.840488612+01:00","text":"9"},{"id":"16b8421d-3c99-4984-9f93-980609550fbd","created_at":"2023-12-17T18:25:29.840490018+01:00","updated_at":"2023-12-17T18:25:29.840490059+01:00","text":"7"},{"id":"cd9ed4bf-2d64-4da9-823a-626d935e30a0","created_at":"2023-12-17T18:25:29.840431459+01:00","updated_at":"2023-12-17T18:25:29.840431554+01:00","text":"2"},{"id":"3fee1c19-1e4e-483d-8fe7-5e61444b5938","created_at":"2023-12-17T18:25:29.840492484+01:00","updated_at":"2023-12-17T18:25:29.840492525+01:00","text":"1"}],"tags":[],"correct":{"id":"6b5f9986-975f-408e-b0b6-ed224e920dc6","created_at":"2023-12-17T18:25:29.840488541+01:00","updated_at":"2023-12-17T18:25:29.840488612+01:00","text":"9"},"CorrectPos":0,"type":0}]} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/participants/andrea.json b/cmd/probo-cli/testdata/participants/andrea.json new file mode 100644 index 0000000..05155e5 --- /dev/null +++ b/cmd/probo-cli/testdata/participants/andrea.json @@ -0,0 +1 @@ +{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:48:05.374673068+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/participants/participant.json b/cmd/probo-cli/testdata/participants/participant.json new file mode 100644 index 0000000..3c8a84d --- /dev/null +++ b/cmd/probo-cli/testdata/participants/participant.json @@ -0,0 +1 @@ +{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:48:05.374735039+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/quizzes/quiz_1.md b/cmd/probo-cli/testdata/quizzes/quiz_1.md new file mode 100644 index 0000000..e3a70db --- /dev/null +++ b/cmd/probo-cli/testdata/quizzes/quiz_1.md @@ -0,0 +1,11 @@ +--- +id: 44812a5d-3391-4401-8b81-bd35df1ef589 +created_at: 2023-12-14T17:58:09.062782001+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Quanto fa 1+1? + +* 2 +* 3 +* 4 +* 0 diff --git a/cmd/probo-cli/testdata/quizzes/quiz_2.md b/cmd/probo-cli/testdata/quizzes/quiz_2.md new file mode 100644 index 0000000..63f13ea --- /dev/null +++ b/cmd/probo-cli/testdata/quizzes/quiz_2.md @@ -0,0 +1,11 @@ +--- +id: 64fb2348-e9b7-497a-97bb-2c1213a4d691 +created_at: 2023-12-14T17:58:09.06290311+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Quanto da 3*3? + +* 9 +* 7 +* 2 +* 1 diff --git a/cmd/probo-cli/testdata/quizzes/quiz_3.md b/cmd/probo-cli/testdata/quizzes/quiz_3.md new file mode 100644 index 0000000..a12abab --- /dev/null +++ b/cmd/probo-cli/testdata/quizzes/quiz_3.md @@ -0,0 +1,11 @@ +--- +id: 67bb31ec-11fe-4e41-9554-a49c8c3dc9ca +created_at: 2023-12-17T15:05:05.91016291+01:00 +updated_at: 0001-01-01T00:00:00Z +--- +Un campo elettrico + +* E' un campo di forse conservative +* E' un campo di forze non conservative +* E' un campo di grano +* E' un campo di calcio diff --git a/cmd/probo-cli/testdata/responses/response_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json b/cmd/probo-cli/testdata/responses/response_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json new file mode 100644 index 0000000..ace8e11 --- /dev/null +++ b/cmd/probo-cli/testdata/responses/response_0c3393eb-34c1-487b-b0c5-ad2df2ea91b6.json @@ -0,0 +1 @@ +{"id":"0c3393eb-34c1-487b-b0c5-ad2df2ea91b6","created_at":"2023-12-17T18:25:14.626099943+01:00","updated_at":"2023-12-17T18:33:13.218190593+01:00","Questions":{"1ff08b57-dac7-4ab4-9874-a351e69b5395":"a6e06a37-4151-4883-a80a-a4b8ffb71254","4ad789b0-cf77-42cd-bce6-d81d52113c01":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","cbc95a46-e728-49b5-b865-9645f8859ae3":"af791e2f-7f5b-4732-b78f-20d810c0d71f"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/responses/response_a0a419aa-31a8-4add-8a39-33a8cb0be381.json b/cmd/probo-cli/testdata/responses/response_a0a419aa-31a8-4add-8a39-33a8cb0be381.json new file mode 100644 index 0000000..56a6c5c --- /dev/null +++ b/cmd/probo-cli/testdata/responses/response_a0a419aa-31a8-4add-8a39-33a8cb0be381.json @@ -0,0 +1 @@ +{"id":"a0a419aa-31a8-4add-8a39-33a8cb0be381","created_at":"2023-12-17T18:27:40.702882786+01:00","updated_at":"2023-12-17T18:33:13.218444916+01:00","Questions":{"1ff08b57-dac7-4ab4-9874-a351e69b5395":"a6e06a37-4151-4883-a80a-a4b8ffb71254","4ad789b0-cf77-42cd-bce6-d81d52113c01":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","cbc95a46-e728-49b5-b865-9645f8859ae3":"af791e2f-7f5b-4732-b78f-20d810c0d71f"}} \ No newline at end of file diff --git a/cmd/probo-cli/testdata/sessions/session_d580ecd7-486a-40d1-9512-a5121f5b1ebb.json b/cmd/probo-cli/testdata/sessions/session_d580ecd7-486a-40d1-9512-a5121f5b1ebb.json new file mode 100644 index 0000000..5c4054a --- /dev/null +++ b/cmd/probo-cli/testdata/sessions/session_d580ecd7-486a-40d1-9512-a5121f5b1ebb.json @@ -0,0 +1 @@ +{"id":"d580ecd7-486a-40d1-9512-a5121f5b1ebb","created_at":"2023-12-17T18:18:29.15717389+01:00","updated_at":"2023-12-17T18:48:05.374449282+01:00","Name":"My Session","Exams":{"111222":{"id":"a0a419aa-31a8-4add-8a39-33a8cb0be381","created_at":"2023-12-17T18:18:29.154872907+01:00","updated_at":"2023-12-17T18:18:29.154873011+01:00","SessionID":"","Participant":{"id":"1234","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:18:29.154592726+01:00","Firstname":"Giuly","Lastname":"Mon Amour","Token":"111222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:18:29.154780203+01:00","hash":"","question":{"id":"1ff08b57-dac7-4ab4-9874-a351e69b5395","created_at":"2023-12-17T18:18:29.154768352+01:00","updated_at":"2023-12-17T18:18:29.154768427+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},{"id":"8f643ed0-c6da-460c-a620-7abacbec54e7","created_at":"2023-12-17T18:18:29.154771507+01:00","updated_at":"2023-12-17T18:18:29.154771548+01:00","text":"7"},{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"a3754b2a-e94a-4065-87d9-443a593106c0","created_at":"2023-12-17T18:18:29.154773883+01:00","updated_at":"2023-12-17T18:18:29.154773925+01:00","text":"1"}],"tags":[],"correct":{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:18:29.154835367+01:00","hash":"","question":{"id":"cbc95a46-e728-49b5-b865-9645f8859ae3","created_at":"2023-12-17T18:18:29.154814412+01:00","updated_at":"2023-12-17T18:18:29.154814466+01:00","text":"Un campo elettrico"},"answers":[{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},{"id":"19b026fd-0a7e-4894-8c75-d7c8a3bdae18","created_at":"2023-12-17T18:18:29.154818196+01:00","updated_at":"2023-12-17T18:18:29.154818239+01:00","text":"E' un campo di forze non conservative"},{"id":"c44d2c2f-385a-468e-8357-43cecf314231","created_at":"2023-12-17T18:18:29.154820248+01:00","updated_at":"2023-12-17T18:18:29.154820288+01:00","text":"E' un campo di grano"},{"id":"817e4b82-63ee-4bb0-be10-9d7dbdeeb704","created_at":"2023-12-17T18:18:29.154827893+01:00","updated_at":"2023-12-17T18:18:29.154827934+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0},{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:18:29.154733234+01:00","hash":"","question":{"id":"4ad789b0-cf77-42cd-bce6-d81d52113c01","created_at":"2023-12-17T18:18:29.154713359+01:00","updated_at":"2023-12-17T18:18:29.154713469+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"8c9b57b2-2f84-4da7-b3e4-217e5b5902aa","created_at":"2023-12-17T18:18:29.154717796+01:00","updated_at":"2023-12-17T18:18:29.154717836+01:00","text":"3"},{"id":"74bf51a1-ce46-4360-a2a6-7b19983181db","created_at":"2023-12-17T18:18:29.154719331+01:00","updated_at":"2023-12-17T18:18:29.154719394+01:00","text":"4"},{"id":"2d0d2f0f-48b6-4aab-aa1d-5caa99d5b11f","created_at":"2023-12-17T18:18:29.154720823+01:00","updated_at":"2023-12-17T18:18:29.154720864+01:00","text":"0"}],"tags":[],"correct":{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},"CorrectPos":0,"type":0}]},"333222":{"id":"0c3393eb-34c1-487b-b0c5-ad2df2ea91b6","created_at":"2023-12-17T18:18:29.155046395+01:00","updated_at":"2023-12-17T18:18:29.155046517+01:00","SessionID":"","Participant":{"id":"564d0c7f-4840-443c-8325-ecd02d03624d","created_at":"2023-12-05T21:11:37.566330708+01:00","updated_at":"2023-12-17T18:18:29.154447458+01:00","Firstname":"Andrea","Lastname":"Fazzi","Token":"333222","Attributes":{"class":"1 D LIN"}},"Quizzes":[{"id":"44812a5d-3391-4401-8b81-bd35df1ef589","created_at":"2023-12-14T17:58:09.062782001+01:00","updated_at":"2023-12-17T18:18:29.154733234+01:00","hash":"","question":{"id":"4ad789b0-cf77-42cd-bce6-d81d52113c01","created_at":"2023-12-17T18:18:29.154713359+01:00","updated_at":"2023-12-17T18:18:29.154713469+01:00","text":"Quanto fa 1+1?"},"answers":[{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"8c9b57b2-2f84-4da7-b3e4-217e5b5902aa","created_at":"2023-12-17T18:18:29.154717796+01:00","updated_at":"2023-12-17T18:18:29.154717836+01:00","text":"3"},{"id":"74bf51a1-ce46-4360-a2a6-7b19983181db","created_at":"2023-12-17T18:18:29.154719331+01:00","updated_at":"2023-12-17T18:18:29.154719394+01:00","text":"4"},{"id":"2d0d2f0f-48b6-4aab-aa1d-5caa99d5b11f","created_at":"2023-12-17T18:18:29.154720823+01:00","updated_at":"2023-12-17T18:18:29.154720864+01:00","text":"0"}],"tags":[],"correct":{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},"CorrectPos":0,"type":0},{"id":"64fb2348-e9b7-497a-97bb-2c1213a4d691","created_at":"2023-12-14T17:58:09.06290311+01:00","updated_at":"2023-12-17T18:18:29.154780203+01:00","hash":"","question":{"id":"1ff08b57-dac7-4ab4-9874-a351e69b5395","created_at":"2023-12-17T18:18:29.154768352+01:00","updated_at":"2023-12-17T18:18:29.154768427+01:00","text":"Quanto da 3*3?"},"answers":[{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},{"id":"8f643ed0-c6da-460c-a620-7abacbec54e7","created_at":"2023-12-17T18:18:29.154771507+01:00","updated_at":"2023-12-17T18:18:29.154771548+01:00","text":"7"},{"id":"c21a9e2d-87d1-4a2e-9f6b-f250e4b8b41d","created_at":"2023-12-17T18:18:29.154716038+01:00","updated_at":"2023-12-17T18:18:29.154716131+01:00","text":"2"},{"id":"a3754b2a-e94a-4065-87d9-443a593106c0","created_at":"2023-12-17T18:18:29.154773883+01:00","updated_at":"2023-12-17T18:18:29.154773925+01:00","text":"1"}],"tags":[],"correct":{"id":"a6e06a37-4151-4883-a80a-a4b8ffb71254","created_at":"2023-12-17T18:18:29.154770004+01:00","updated_at":"2023-12-17T18:18:29.154770068+01:00","text":"9"},"CorrectPos":0,"type":0},{"id":"67bb31ec-11fe-4e41-9554-a49c8c3dc9ca","created_at":"2023-12-17T15:05:05.91016291+01:00","updated_at":"2023-12-17T18:18:29.154835367+01:00","hash":"","question":{"id":"cbc95a46-e728-49b5-b865-9645f8859ae3","created_at":"2023-12-17T18:18:29.154814412+01:00","updated_at":"2023-12-17T18:18:29.154814466+01:00","text":"Un campo elettrico"},"answers":[{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},{"id":"19b026fd-0a7e-4894-8c75-d7c8a3bdae18","created_at":"2023-12-17T18:18:29.154818196+01:00","updated_at":"2023-12-17T18:18:29.154818239+01:00","text":"E' un campo di forze non conservative"},{"id":"c44d2c2f-385a-468e-8357-43cecf314231","created_at":"2023-12-17T18:18:29.154820248+01:00","updated_at":"2023-12-17T18:18:29.154820288+01:00","text":"E' un campo di grano"},{"id":"817e4b82-63ee-4bb0-be10-9d7dbdeeb704","created_at":"2023-12-17T18:18:29.154827893+01:00","updated_at":"2023-12-17T18:18:29.154827934+01:00","text":"E' un campo di calcio"}],"tags":[],"correct":{"id":"af791e2f-7f5b-4732-b78f-20d810c0d71f","created_at":"2023-12-17T18:18:29.15481594+01:00","updated_at":"2023-12-17T18:18:29.154815984+01:00","text":"E' un campo di forse conservative"},"CorrectPos":0,"type":0}]}}} \ No newline at end of file diff --git a/go.mod b/go.mod index 2373a0a..3b013ea 100644 --- a/go.mod +++ b/go.mod @@ -1,36 +1,41 @@ module git.andreafazzi.eu/andrea/probo -go 1.21 +go 1.21.5 require ( - github.com/gocarina/gocsv v0.0.0-20230616125104-99d496ca653d - github.com/google/uuid v1.3.1 - github.com/julienschmidt/httprouter v1.3.0 - github.com/sirupsen/logrus v1.8.1 + github.com/charmbracelet/bubbles v0.17.1 + github.com/charmbracelet/bubbletea v0.25.0 + github.com/gocarina/gocsv v0.0.0-20231116093920-b87c2d0e983a + github.com/google/uuid v1.5.0 + github.com/lmittmann/tint v1.0.3 + github.com/remogatto/prettytest v0.0.0-20200211072524-6d385e11dcb8 + github.com/urfave/cli/v2 v2.26.0 gopkg.in/yaml.v2 v2.4.0 gorm.io/gorm v1.25.5 ) require ( + github.com/atotto/clipboard v0.1.4 // indirect + github.com/aymanbagabas/go-osc52/v2 v2.0.1 // indirect + github.com/charmbracelet/lipgloss v0.9.1 // indirect + github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect - github.com/dustin/go-humanize v1.0.1 // indirect - github.com/glebarez/go-sqlite v1.21.2 // indirect - github.com/glebarez/sqlite v1.9.0 // indirect - github.com/go-yaml/yaml v2.1.0+incompatible // indirect github.com/jinzhu/inflection v1.0.0 // indirect github.com/jinzhu/now v1.1.5 // indirect - github.com/kr/pretty v0.2.1 // indirect - github.com/kr/text v0.1.0 // indirect - github.com/mattn/go-isatty v0.0.20 // indirect - github.com/remogatto/prettytest v0.0.0-20200211072524-6d385e11dcb8 // indirect - github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect + github.com/lucasb-eyer/go-colorful v1.2.0 // indirect + github.com/mattn/go-isatty v0.0.18 // indirect + github.com/mattn/go-localereader v0.0.1 // indirect + github.com/mattn/go-runewidth v0.0.15 // indirect + github.com/muesli/ansi v0.0.0-20211018074035-2e021307bc4b // indirect + github.com/muesli/cancelreader v0.2.2 // indirect + github.com/muesli/reflow v0.3.0 // indirect + github.com/muesli/termenv v0.15.2 // indirect + github.com/rivo/uniseg v0.2.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect - github.com/urfave/cli/v2 v2.26.0 // indirect github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect - golang.org/x/sys v0.13.0 // indirect - gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect - modernc.org/libc v1.24.1 // indirect - modernc.org/mathutil v1.6.0 // indirect - modernc.org/memory v1.7.2 // indirect - modernc.org/sqlite v1.26.0 // indirect + golang.org/x/sync v0.1.0 // indirect + golang.org/x/sys v0.12.0 // indirect + golang.org/x/term v0.6.0 // indirect + golang.org/x/text v0.3.8 // indirect + gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 // indirect ) diff --git a/go.sum b/go.sum index 530149d..4d2db3d 100644 --- a/go.sum +++ b/go.sum @@ -1,64 +1,68 @@ +github.com/atotto/clipboard v0.1.4 h1:EH0zSVneZPSuFR11BlR9YppQTVDbh5+16AmcJi4g1z4= +github.com/atotto/clipboard v0.1.4/go.mod h1:ZY9tmq7sm5xIbd9bOK4onWV4S6X0u6GY7Vn0Yu86PYI= +github.com/aymanbagabas/go-osc52/v2 v2.0.1 h1:HwpRHbFMcZLEVr42D4p7XBqjyuxQH5SMiErDT4WkJ2k= +github.com/aymanbagabas/go-osc52/v2 v2.0.1/go.mod h1:uYgXzlJ7ZpABp8OJ+exZzJJhRNQ2ASbcXHWsFqH8hp8= +github.com/charmbracelet/bubbles v0.17.1 h1:0SIyjOnkrsfDo88YvPgAWvZMwXe26TP6drRvmkjyUu4= +github.com/charmbracelet/bubbles v0.17.1/go.mod h1:9HxZWlkCqz2PRwsCbYl7a3KXvGzFaDHpYbSYMJ+nE3o= +github.com/charmbracelet/bubbletea v0.25.0 h1:bAfwk7jRz7FKFl9RzlIULPkStffg5k6pNt5dywy4TcM= +github.com/charmbracelet/bubbletea v0.25.0/go.mod h1:EN3QDR1T5ZdWmdfDzYcqOCAps45+QIJbLOBxmVNWNNg= +github.com/charmbracelet/lipgloss v0.9.1 h1:PNyd3jvaJbg4jRHKWXnCj1akQm4rh8dbEzN1p/u1KWg= +github.com/charmbracelet/lipgloss v0.9.1/go.mod h1:1mPmG4cxScwUQALAAnacHaigiiHB9Pmr+v1VEawJl6I= +github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81 h1:q2hJAaP1k2wIvVRd/hEHD7lacgqrCPS+k8g1MndzfWY= +github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81/go.mod h1:YynlIjWYF8myEu6sdkwKIvGQq+cOckRm6So2avqoYAk= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= -github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/glebarez/go-sqlite v1.21.2 h1:3a6LFC4sKahUunAmynQKLZceZCOzUthkRkEAl9gAXWo= -github.com/glebarez/go-sqlite v1.21.2/go.mod h1:sfxdZyhQjTM2Wry3gVYWaW072Ri1WMdWJi0k6+3382k= -github.com/glebarez/sqlite v1.9.0 h1:Aj6bPA12ZEx5GbSF6XADmCkYXlljPNUY+Zf1EQxynXs= -github.com/glebarez/sqlite v1.9.0/go.mod h1:YBYCoyupOao60lzp1MVBLEjZfgkq0tdB1voAQ09K9zw= -github.com/go-yaml/yaml v2.1.0+incompatible h1:RYi2hDdss1u4YE7GwixGzWwVo47T8UQwnTLB6vQiq+o= -github.com/go-yaml/yaml v2.1.0+incompatible/go.mod h1:w2MrLa16VYP0jy6N7M5kHaCkaLENm+P+Tv+MfurjSw0= -github.com/gocarina/gocsv v0.0.0-20230616125104-99d496ca653d h1:KbPOUXFUDJxwZ04vbmDOc3yuruGvVO+LOa7cVER3yWw= -github.com/gocarina/gocsv v0.0.0-20230616125104-99d496ca653d/go.mod h1:5YoVOkjYAQumqlV356Hj3xeYh4BdZuLE0/nRkf2NKkI= -github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= -github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/gocarina/gocsv v0.0.0-20231116093920-b87c2d0e983a h1:RYfmiM0zluBJOiPDJseKLEN4BapJ42uSi9SZBQ2YyiA= +github.com/gocarina/gocsv v0.0.0-20231116093920-b87c2d0e983a/go.mod h1:5YoVOkjYAQumqlV356Hj3xeYh4BdZuLE0/nRkf2NKkI= +github.com/google/uuid v1.5.0 h1:1p67kYwdtXjb0gL0BPiP1Av9wiZPo5A8z2cWkTZ+eyU= +github.com/google/uuid v1.5.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/jinzhu/inflection v1.0.0 h1:K317FqzuhWc8YvSVlFMCCUb36O/S9MCKRDI7QkRKD/E= github.com/jinzhu/inflection v1.0.0/go.mod h1:h+uFLlag+Qp1Va5pdKtLDYj+kHp5pxUVkryuEj+Srlc= github.com/jinzhu/now v1.1.5 h1:/o9tlHleP7gOFmsnYNz3RGnqzefHA47wQpKrrdTIwXQ= github.com/jinzhu/now v1.1.5/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= -github.com/julienschmidt/httprouter v1.3.0 h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI= -github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= -github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= -github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/lmittmann/tint v1.0.3 h1:W5PHeA2D8bBJVvabNfQD/XW9HPLZK1XoPZH0cq8NouQ= +github.com/lmittmann/tint v1.0.3/go.mod h1:HIS3gSy7qNwGCj+5oRjAutErFBl4BzdQP6cJZ0NfMwE= +github.com/lucasb-eyer/go-colorful v1.2.0 h1:1nnpGOrhyZZuNyfu1QjKiUICQ74+3FNCN69Aj6K7nkY= +github.com/lucasb-eyer/go-colorful v1.2.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= +github.com/mattn/go-isatty v0.0.18 h1:DOKFKCQ7FNG2L1rbrmstDN4QVRdS89Nkh85u68Uwp98= +github.com/mattn/go-isatty v0.0.18/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= +github.com/mattn/go-localereader v0.0.1 h1:ygSAOl7ZXTx4RdPYinUpg6W99U8jWvWi9Ye2JC/oIi4= +github.com/mattn/go-localereader v0.0.1/go.mod h1:8fBrzywKY7BI3czFoHkuzRoWE9C+EiG4R1k4Cjx5p88= +github.com/mattn/go-runewidth v0.0.12/go.mod h1:RAqKPSqVFrSLVXbA8x7dzmKdmGzieGRCM46jaSJTDAk= +github.com/mattn/go-runewidth v0.0.15 h1:UNAjwbU9l54TA3KzvqLGxwWjHmMgBUVhBiTjelZgg3U= +github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/muesli/ansi v0.0.0-20211018074035-2e021307bc4b h1:1XF24mVaiu7u+CFywTdcDo2ie1pzzhwjt6RHqzpMU34= +github.com/muesli/ansi v0.0.0-20211018074035-2e021307bc4b/go.mod h1:fQuZ0gauxyBcmsdE3ZT4NasjaRdxmbCS0jRHsrWu3Ho= +github.com/muesli/cancelreader v0.2.2 h1:3I4Kt4BQjOR54NavqnDogx/MIoWBFa0StPA8ELUXHmA= +github.com/muesli/cancelreader v0.2.2/go.mod h1:3XuTXfFS2VjM+HTLZY9Ak0l6eUKfijIfMUZ4EgX0QYo= +github.com/muesli/reflow v0.3.0 h1:IFsN6K9NfGtjeggFP+68I4chLZV2yIKsXJFNZ+eWh6s= +github.com/muesli/reflow v0.3.0/go.mod h1:pbwTDkVPibjO2kyvBQRBxTWEEGDGq0FlB1BIKtnHY/8= +github.com/muesli/termenv v0.15.2 h1:GohcuySI0QmI3wN8Ok9PtKGkgkFIk7y6Vpb5PvrY+Wo= +github.com/muesli/termenv v0.15.2/go.mod h1:Epx+iuz8sNs7mNKhxzH4fWXGNpZwUaJKRS1noLXviQ8= github.com/remogatto/prettytest v0.0.0-20200211072524-6d385e11dcb8 h1:nRDwTcxV9B3elxMt+1xINX0bwaPdpouqp5fbynexY8U= github.com/remogatto/prettytest v0.0.0-20200211072524-6d385e11dcb8/go.mod h1:jOEnp79oIHy5cvQSHeLcgVJk1GHOOHJHQWps/d1N5Yo= -github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE= -github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= +github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= +github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= +github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= -github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/urfave/cli/v2 v2.26.0 h1:3f3AMg3HpThFNT4I++TKOejZO8yU55t3JnnSr4S4QEI= github.com/urfave/cli/v2 v2.26.0/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6SinrnYQ= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037 h1:YyJpGZS1sBuBCzLAR1VEpK193GlqGZbnPFnPV/5Rsb4= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= +golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.12.0 h1:CM0HF96J0hcLAwsHPJZjfdNzs0gftsLfgKt57wWHJ0o= +golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/term v0.6.0 h1:clScbb1cHjoCkyRbWwBEUZ5H/tIFu5TAXIqaZD0Gcjw= +golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= +golang.org/x/text v0.3.8 h1:nAL+RVCQ9uMn3vJZbV+MRnydTJFPf8qqY42YiA6MrqY= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= -gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gorm.io/gorm v1.25.5 h1:zR9lOiiYf09VNh5Q1gphfyia1JpiClIWG9hQaxB/mls= gorm.io/gorm v1.25.5/go.mod h1:hbnx/Oo0ChWMn1BIhpy1oYozzpM15i4YPuHDmfYtwg8= -modernc.org/libc v1.24.1 h1:uvJSeCKL/AgzBo2yYIPPTy82v21KgGnizcGYfBHaNuM= -modernc.org/libc v1.24.1/go.mod h1:FmfO1RLrU3MHJfyi9eYYmZBfi/R+tqZ6+hQ3yQQUkak= -modernc.org/mathutil v1.6.0 h1:fRe9+AmYlaej+64JsEEhoWuAYBkOtQiMEU7n/XgfYi4= -modernc.org/mathutil v1.6.0/go.mod h1:Ui5Q9q1TR2gFm0AQRqQUaBWFLAhQpCwNcuhBOSedWPo= -modernc.org/memory v1.7.2 h1:Klh90S215mmH8c9gO98QxQFsY+W451E8AnzjoE2ee1E= -modernc.org/memory v1.7.2/go.mod h1:NO4NVCQy0N7ln+T9ngWqOQfi7ley4vpwvARR+Hjw95E= -modernc.org/sqlite v1.26.0 h1:SocQdLRSYlA8W99V8YH0NES75thx19d9sB/aFc4R8Lw= -modernc.org/sqlite v1.26.0/go.mod h1:FL3pVXie73rg3Rii6V/u5BoHlSoyeZeIgKZEgHARyCU= diff --git a/hasher/hasher.go b/hasher/hasher.go deleted file mode 100644 index 64b036a..0000000 --- a/hasher/hasher.go +++ /dev/null @@ -1,26 +0,0 @@ -package hasher - -import ( - "git.andreafazzi.eu/andrea/probo/client" -) - -type HashFunc func(string) string - -type Hasher interface { - // Hash returns a slice of hashes. The first one is an - // hash calculated from the question using - // QuestionHash. Following hashes are calculated from the - // answers using AnswerHash. - QuizHashes(quiz *client.Quiz) []string - - // QuestionHash returns an hash calculated from a field of - // Question struct. - QuestionHash(question *client.Question) string - - // AnswerHash returns an hash calculated from a field of - // Answer struct. - AnswerHash(answer *client.Answer) string - - // Calculate calculates a checksum from all the given hashes. - Calculate(hashes []string) string -} diff --git a/hasher/hasher_test.go b/hasher/hasher_test.go deleted file mode 100644 index 6662224..0000000 --- a/hasher/hasher_test.go +++ /dev/null @@ -1,64 +0,0 @@ -package hasher - -import ( - "testing" - - "git.andreafazzi.eu/andrea/probo/client" - "github.com/remogatto/prettytest" -) - -type testSuite struct { - prettytest.Suite -} - -func TestRunner(t *testing.T) { - prettytest.Run( - t, - new(testSuite), - ) -} - -func (t *testSuite) TestQuizHashes() { - h := NewDefaultHash(DefaultSHA256HashingFn) - - firstQuizRequest := &client.CreateQuizRequest{ - Question: &client.CreateQuestionRequest{ - Text: "Question 1"}, - Answers: []*client.CreateAnswerRequest{ - {Text: "Answer 2", Correct: false}, - {Text: "Answer 3", Correct: false}, - {Text: "Answer 1", Correct: true}, - }, - } - - secondQuizRequest := &client.CreateQuizRequest{ - Question: &client.CreateQuestionRequest{ - Text: "Question 1"}, - Answers: []*client.CreateAnswerRequest{ - {Text: "Answer 1", Correct: false}, - {Text: "Answer 2", Correct: false}, - {Text: "Answer 3", Correct: true}, - }, - } - - thirdQuizRequest := &client.CreateQuizRequest{ - Question: &client.CreateQuestionRequest{ - Text: "Question 2"}, - Answers: []*client.CreateAnswerRequest{ - {Text: "Answer 1", Correct: false}, - {Text: "Answer 2", Correct: false}, - {Text: "Answer 3", Correct: true}, - }, - } - - hashesFromFirstRequest := h.QuizHashes(firstQuizRequest) - hashesFromSecondRequest := h.QuizHashes(secondQuizRequest) - hashesFromThirdRequest := h.QuizHashes(thirdQuizRequest) - - t.Equal(5, len(hashesFromFirstRequest)) - - t.True(hashesFromFirstRequest[1] == hashesFromSecondRequest[2], "Answers' hashes should maintain original request's order") - t.True(hashesFromFirstRequest[4] == hashesFromSecondRequest[4], "Quiz hash should be the same because quizzes are duplicated") - t.True(hashesFromFirstRequest[1] != hashesFromThirdRequest[1], "Questions' hashes should not be the same because texts are different") - t.True(hashesFromFirstRequest[4] != hashesFromThirdRequest[4], "Quiz hash should not be the same because quizzes are not duplicated") -} diff --git a/hasher/sha256/sha256.go b/hasher/sha256/sha256.go deleted file mode 100644 index 169c639..0000000 --- a/hasher/sha256/sha256.go +++ /dev/null @@ -1,54 +0,0 @@ -package sha256 - -import ( - "crypto/sha256" - "fmt" - "sort" - "strings" - - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/hasher" -) - -var DefaultSHA256HashingFn = func(text string) string { - return fmt.Sprintf("%x", sha256.Sum256([]byte(text))) -} - -type Default256Hasher struct { - hashFn hasher.HashFunc -} - -func NewDefault256Hasher(hashFn hasher.HashFunc) *Default256Hasher { - return &Default256Hasher{hashFn} -} - -func (h *Default256Hasher) QuizHashes(quiz *client.Quiz) []string { - result := make([]string, 0) - - result = append(result, h.QuestionHash(quiz.Question)) - - for _, a := range quiz.Answers { - result = append(result, h.AnswerHash(a)) - } - - result = append(result, h.Calculate(result)) - - return result -} - -func (h *Default256Hasher) QuestionHash(question *client.Question) string { - return h.hashFn(question.Text) -} - -func (h *Default256Hasher) AnswerHash(answer *client.Answer) string { - return h.hashFn(answer.Text) -} - -func (h *Default256Hasher) Calculate(hashes []string) string { - orderedHashes := make([]string, len(hashes)) - - copy(orderedHashes, hashes) - sort.Strings(orderedHashes) - - return h.hashFn(strings.Join(orderedHashes, "")) -} diff --git a/models/answer.go b/lib/models/answer.go similarity index 100% rename from models/answer.go rename to lib/models/answer.go diff --git a/models/collection.go b/lib/models/collection.go similarity index 100% rename from models/collection.go rename to lib/models/collection.go diff --git a/models/exam.go b/lib/models/exam.go similarity index 100% rename from models/exam.go rename to lib/models/exam.go diff --git a/models/filters.go b/lib/models/filters.go similarity index 100% rename from models/filters.go rename to lib/models/filters.go diff --git a/models/group.go b/lib/models/group.go similarity index 100% rename from models/group.go rename to lib/models/group.go diff --git a/models/group_test.go b/lib/models/group_test.go similarity index 100% rename from models/group_test.go rename to lib/models/group_test.go diff --git a/models/meta.go b/lib/models/meta.go similarity index 100% rename from models/meta.go rename to lib/models/meta.go diff --git a/models/models_test.go b/lib/models/models_test.go similarity index 100% rename from models/models_test.go rename to lib/models/models_test.go diff --git a/models/participant.go b/lib/models/participant.go similarity index 88% rename from models/participant.go rename to lib/models/participant.go index c2b8472..aaf028b 100644 --- a/models/participant.go +++ b/lib/models/participant.go @@ -4,6 +4,7 @@ import ( "crypto/sha256" "encoding/json" "fmt" + "log" "sort" "strings" ) @@ -14,12 +15,12 @@ type Participant struct { // ID string `csv:"id" gorm:"primaryKey"` Meta - Firstname string `csv:"firstname"` - Lastname string `csv:"lastname"` + Firstname string + Lastname string - Token string `csv:"token"` + Token string - Attributes AttributeList `csv:"attributes"` + Attributes AttributeList `csv:"Attributes"` } func (p *Participant) String() string { @@ -55,11 +56,16 @@ func (al AttributeList) MarshalCSV() (string, error) { } func (al AttributeList) UnmarshalCSV(csv string) error { + log.Println("test") al = make(map[string]string) al["foo"] = "bar" return nil } +func (al AttributeList) Get(key string) string { + return al[key] +} + func convertMapToKeyValueOrderedString(m map[string]string) string { keys := make([]string, 0, len(m)) for key := range m { diff --git a/models/player.go b/lib/models/player.go similarity index 100% rename from models/player.go rename to lib/models/player.go diff --git a/models/question.go b/lib/models/question.go similarity index 100% rename from models/question.go rename to lib/models/question.go diff --git a/models/quiz.go b/lib/models/quiz.go similarity index 100% rename from models/quiz.go rename to lib/models/quiz.go diff --git a/models/response.go b/lib/models/response.go similarity index 100% rename from models/response.go rename to lib/models/response.go diff --git a/models/session.go b/lib/models/session.go similarity index 100% rename from models/session.go rename to lib/models/session.go diff --git a/models/tag.go b/lib/models/tag.go similarity index 100% rename from models/tag.go rename to lib/models/tag.go diff --git a/sessionmanager/score.go b/lib/sessionmanager/score.go similarity index 90% rename from sessionmanager/score.go rename to lib/sessionmanager/score.go index a2974b6..33ec490 100644 --- a/sessionmanager/score.go +++ b/lib/sessionmanager/score.go @@ -4,8 +4,8 @@ import ( "fmt" "log" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store/file" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store/file" ) type Score struct { diff --git a/sessionmanager/sessionmanager.go b/lib/sessionmanager/sessionmanager.go similarity index 94% rename from sessionmanager/sessionmanager.go rename to lib/sessionmanager/sessionmanager.go index acbf4c2..d30371f 100644 --- a/sessionmanager/sessionmanager.go +++ b/lib/sessionmanager/sessionmanager.go @@ -7,9 +7,9 @@ import ( "net/http" "net/url" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" - "git.andreafazzi.eu/andrea/probo/store/file" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" + "git.andreafazzi.eu/andrea/probo/lib/store/file" ) type SessionManager struct { diff --git a/store/exam.go b/lib/store/exam.go similarity index 50% rename from store/exam.go rename to lib/store/exam.go index 5bc2d30..b3c3990 100644 --- a/store/exam.go +++ b/lib/store/exam.go @@ -1,5 +1,5 @@ package store -import "git.andreafazzi.eu/andrea/probo/models" +import "git.andreafazzi.eu/andrea/probo/lib/models" type ExamStore = Store[*models.Exam] diff --git a/store/file/defaults.go b/lib/store/file/defaults.go similarity index 100% rename from store/file/defaults.go rename to lib/store/file/defaults.go diff --git a/store/file/exam.go b/lib/store/file/exam.go similarity index 89% rename from store/file/exam.go rename to lib/store/file/exam.go index 3cd44cd..556d4ed 100644 --- a/store/file/exam.go +++ b/lib/store/file/exam.go @@ -1,8 +1,8 @@ package file import ( - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" ) type ExamFileStore = FileStore[*models.Exam, *store.Store[*models.Exam]] diff --git a/store/file/exam_test.go b/lib/store/file/exam_test.go similarity index 96% rename from store/file/exam_test.go rename to lib/store/file/exam_test.go index a40583c..7d1adcc 100644 --- a/store/file/exam_test.go +++ b/lib/store/file/exam_test.go @@ -6,8 +6,8 @@ import ( "io" "os" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" "github.com/remogatto/prettytest" ) diff --git a/store/file/file.go b/lib/store/file/file.go similarity index 98% rename from store/file/file.go rename to lib/store/file/file.go index 067f459..510fb75 100644 --- a/store/file/file.go +++ b/lib/store/file/file.go @@ -9,7 +9,7 @@ import ( "strings" "sync" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/store" ) type IndexDirFunc[T FileStorable, K Storer[T]] func(s *FileStore[T, K]) error diff --git a/store/file/file_test.go b/lib/store/file/file_test.go similarity index 100% rename from store/file/file_test.go rename to lib/store/file/file_test.go diff --git a/store/file/participant.go b/lib/store/file/participant.go similarity index 90% rename from store/file/participant.go rename to lib/store/file/participant.go index 7e05483..6fad278 100644 --- a/store/file/participant.go +++ b/lib/store/file/participant.go @@ -1,8 +1,8 @@ package file import ( - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" ) type ParticipantFileStore = FileStore[*models.Participant, *store.ParticipantStore] diff --git a/store/file/participant_test.go b/lib/store/file/participant_test.go similarity index 92% rename from store/file/participant_test.go rename to lib/store/file/participant_test.go index 1ea41dd..fc3760f 100644 --- a/store/file/participant_test.go +++ b/lib/store/file/participant_test.go @@ -3,7 +3,7 @@ package file import ( "os" - "git.andreafazzi.eu/andrea/probo/models" + "git.andreafazzi.eu/andrea/probo/lib/models" "github.com/remogatto/prettytest" ) diff --git a/store/file/quiz.go b/lib/store/file/quiz.go similarity index 97% rename from store/file/quiz.go rename to lib/store/file/quiz.go index 04beeb2..2b188c1 100644 --- a/store/file/quiz.go +++ b/lib/store/file/quiz.go @@ -11,8 +11,8 @@ import ( "strings" "time" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" "gopkg.in/yaml.v2" ) diff --git a/store/file/quiz_test.go b/lib/store/file/quiz_test.go similarity index 98% rename from store/file/quiz_test.go rename to lib/store/file/quiz_test.go index a46a3e9..e584bc4 100644 --- a/store/file/quiz_test.go +++ b/lib/store/file/quiz_test.go @@ -5,8 +5,8 @@ import ( "os" "path/filepath" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" "github.com/remogatto/prettytest" ) diff --git a/store/file/response.go b/lib/store/file/response.go similarity index 88% rename from store/file/response.go rename to lib/store/file/response.go index e78b04b..2541eae 100644 --- a/store/file/response.go +++ b/lib/store/file/response.go @@ -1,8 +1,8 @@ package file import ( - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" ) type ResponseFileStore = FileStore[*models.Response, *store.Store[*models.Response]] diff --git a/store/file/session.go b/lib/store/file/session.go similarity index 88% rename from store/file/session.go rename to lib/store/file/session.go index 870f34b..5aedc04 100644 --- a/store/file/session.go +++ b/lib/store/file/session.go @@ -1,8 +1,8 @@ package file import ( - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" ) type SessionFileStore = FileStore[*models.Session, *store.Store[*models.Session]] diff --git a/store/file/testdata/exams/participants/jack.json b/lib/store/file/testdata/exams/participants/jack.json similarity index 100% rename from store/file/testdata/exams/participants/jack.json rename to lib/store/file/testdata/exams/participants/jack.json diff --git a/store/file/testdata/exams/participants/john.json b/lib/store/file/testdata/exams/participants/john.json similarity index 100% rename from store/file/testdata/exams/participants/john.json rename to lib/store/file/testdata/exams/participants/john.json diff --git a/store/file/testdata/exams/participants/wendy.json b/lib/store/file/testdata/exams/participants/wendy.json similarity index 100% rename from store/file/testdata/exams/participants/wendy.json rename to lib/store/file/testdata/exams/participants/wendy.json diff --git a/store/file/testdata/exams/quizzes/quiz_1.md b/lib/store/file/testdata/exams/quizzes/quiz_1.md similarity index 100% rename from store/file/testdata/exams/quizzes/quiz_1.md rename to lib/store/file/testdata/exams/quizzes/quiz_1.md diff --git a/store/file/testdata/exams/quizzes/quiz_2.md b/lib/store/file/testdata/exams/quizzes/quiz_2.md similarity index 100% rename from store/file/testdata/exams/quizzes/quiz_2.md rename to lib/store/file/testdata/exams/quizzes/quiz_2.md diff --git a/store/file/testdata/exams/quizzes/quiz_3.md b/lib/store/file/testdata/exams/quizzes/quiz_3.md similarity index 100% rename from store/file/testdata/exams/quizzes/quiz_3.md rename to lib/store/file/testdata/exams/quizzes/quiz_3.md diff --git a/store/file/testdata/quizzes/quiz_1.md b/lib/store/file/testdata/quizzes/quiz_1.md similarity index 100% rename from store/file/testdata/quizzes/quiz_1.md rename to lib/store/file/testdata/quizzes/quiz_1.md diff --git a/store/file/testdata/quizzes/quiz_2.md b/lib/store/file/testdata/quizzes/quiz_2.md similarity index 100% rename from store/file/testdata/quizzes/quiz_2.md rename to lib/store/file/testdata/quizzes/quiz_2.md diff --git a/store/file/testdata/quizzes/quiz_3.md b/lib/store/file/testdata/quizzes/quiz_3.md similarity index 100% rename from store/file/testdata/quizzes/quiz_3.md rename to lib/store/file/testdata/quizzes/quiz_3.md diff --git a/store/file/testdata/quizzes/quiz_4.md b/lib/store/file/testdata/quizzes/quiz_4.md similarity index 100% rename from store/file/testdata/quizzes/quiz_4.md rename to lib/store/file/testdata/quizzes/quiz_4.md diff --git a/store/file/testdata/quizzes/quiz_5.md b/lib/store/file/testdata/quizzes/quiz_5.md similarity index 100% rename from store/file/testdata/quizzes/quiz_5.md rename to lib/store/file/testdata/quizzes/quiz_5.md diff --git a/store/participant.go b/lib/store/participant.go similarity index 61% rename from store/participant.go rename to lib/store/participant.go index 4e5875e..776011c 100644 --- a/store/participant.go +++ b/lib/store/participant.go @@ -1,6 +1,11 @@ package store -import "git.andreafazzi.eu/andrea/probo/models" +import ( + "os" + + "git.andreafazzi.eu/andrea/probo/lib/models" + "github.com/gocarina/gocsv" +) type ParticipantStore struct { *FilterStore[*models.Participant] @@ -13,6 +18,21 @@ func NewParticipantStore() *ParticipantStore { return store } +func (s *ParticipantStore) ImportCSV(path string) ([]*models.Participant, error) { + file, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE, os.ModePerm) + if err != nil { + return nil, err + } + defer file.Close() + + participants := []*models.Participant{} + + if err := gocsv.UnmarshalFile(file, &participants); err != nil { + return nil, err + } + return participants, nil +} + func (s *ParticipantStore) FilterInGroup(group *models.Group, filter map[string]string) []*models.Participant { participants := s.ReadAll() diff --git a/store/participant_test.go b/lib/store/participant_test.go similarity index 75% rename from store/participant_test.go rename to lib/store/participant_test.go index 0b93005..201143c 100644 --- a/store/participant_test.go +++ b/lib/store/participant_test.go @@ -1,7 +1,7 @@ package store import ( - "git.andreafazzi.eu/andrea/probo/models" + "git.andreafazzi.eu/andrea/probo/lib/models" "github.com/remogatto/prettytest" ) @@ -50,3 +50,13 @@ func (t *participantTestSuite) TestUpdate() { t.False(p.GetHash() == updatedP.GetHash()) } + +func (t *participantTestSuite) TestImportCSV() { + store := NewParticipantStore() + + participants, err := store.ImportCSV("./testdata/participants.csv") + + t.Nil(err) + t.Equal(3, len(participants)) + t.Equal("1 D LIN", participants[0].Attributes.Get("class")) +} diff --git a/store/quiz.go b/lib/store/quiz.go similarity index 98% rename from store/quiz.go rename to lib/store/quiz.go index 2b2715f..1d59612 100644 --- a/store/quiz.go +++ b/lib/store/quiz.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "git.andreafazzi.eu/andrea/probo/models" + "git.andreafazzi.eu/andrea/probo/lib/models" ) type ErrQuizAlreadyPresent struct { diff --git a/store/quiz_test.go b/lib/store/quiz_test.go similarity index 99% rename from store/quiz_test.go rename to lib/store/quiz_test.go index d24cb57..31e60e8 100644 --- a/store/quiz_test.go +++ b/lib/store/quiz_test.go @@ -3,7 +3,7 @@ package store import ( "reflect" - "git.andreafazzi.eu/andrea/probo/models" + "git.andreafazzi.eu/andrea/probo/lib/models" "github.com/remogatto/prettytest" ) diff --git a/store/response.go b/lib/store/response.go similarity index 53% rename from store/response.go rename to lib/store/response.go index 72c3999..c93cc16 100644 --- a/store/response.go +++ b/lib/store/response.go @@ -1,5 +1,5 @@ package store -import "git.andreafazzi.eu/andrea/probo/models" +import "git.andreafazzi.eu/andrea/probo/lib/models" type ResponseStore = Store[*models.Response] diff --git a/store/session.go b/lib/store/session.go similarity index 53% rename from store/session.go rename to lib/store/session.go index 909c1f7..8a148c3 100644 --- a/store/session.go +++ b/lib/store/session.go @@ -1,5 +1,5 @@ package store -import "git.andreafazzi.eu/andrea/probo/models" +import "git.andreafazzi.eu/andrea/probo/lib/models" type SessionStore = Store[*models.Session] diff --git a/store/store.go b/lib/store/store.go similarity index 100% rename from store/store.go rename to lib/store/store.go diff --git a/store/store_test.go b/lib/store/store_test.go similarity index 86% rename from store/store_test.go rename to lib/store/store_test.go index 2a2c353..e4804b0 100644 --- a/store/store_test.go +++ b/lib/store/store_test.go @@ -10,7 +10,6 @@ func TestRunner(t *testing.T) { prettytest.Run( t, new(quizTestSuite), - new(collectionTestSuite), new(participantTestSuite), ) } diff --git a/lib/store/testdata/participants.csv b/lib/store/testdata/participants.csv new file mode 100644 index 0000000..217ffa4 --- /dev/null +++ b/lib/store/testdata/participants.csv @@ -0,0 +1,4 @@ +Lastname,Firstname,Token,Attributes +CABRERA,GAIA,982998,class:1 D LIN +VERDI,ANNA,868424,class:1 D LIN +BIANCHI,ELENA,795233,class:1 D LIN diff --git a/logger/logger.go b/logger/logger.go deleted file mode 100644 index 130107b..0000000 --- a/logger/logger.go +++ /dev/null @@ -1,112 +0,0 @@ -package logger - -import ( - "log" - "net/http" - "time" - - "github.com/sirupsen/logrus" -) - -const ( - Disabled = iota - InfoLevel - WarningLevel - DebugLevel -) - -type ( - // struct for holding response details - responseData struct { - status int - size int - } - - // our http.ResponseWriter implementation - loggingResponseWriter struct { - http.ResponseWriter // compose original http.ResponseWriter - responseData *responseData - } -) - -var loggerLevel int = InfoLevel - -func (r *loggingResponseWriter) Write(b []byte) (int, error) { - size, err := r.ResponseWriter.Write(b) // write response using original http.ResponseWriter - r.responseData.size += size // capture size - return size, err -} - -func (r *loggingResponseWriter) WriteHeader(statusCode int) { - r.ResponseWriter.WriteHeader(statusCode) // write status code using original http.ResponseWriter - r.responseData.status = statusCode // capture status code -} - -func WithLogging(h http.Handler) http.Handler { - loggingFn := func(rw http.ResponseWriter, req *http.Request) { - start := time.Now() - - responseData := &responseData{ - status: 0, - size: 0, - } - lrw := loggingResponseWriter{ - ResponseWriter: rw, // compose original http.ResponseWriter - responseData: responseData, - } - h.ServeHTTP(&lrw, req) // inject our implementation of http.ResponseWriter - - duration := time.Since(start) - - if loggerLevel >= InfoLevel { - logrus.WithFields(logrus.Fields{ - "URI": req.RequestURI, - "Method": req.Method, - "Status": responseData.status, - "Duration": duration, - "Size": responseData.size, - }).Info("Completed.") - } - } - return http.HandlerFunc(loggingFn) -} - -func SetLevel(level int) { - loggerLevel = level -} - -func Info(v ...interface{}) { - if loggerLevel >= InfoLevel { - log.Println(v...) - } -} - -func Infof(format string, v ...interface{}) { - if loggerLevel >= InfoLevel { - log.Printf(format, v...) - } -} - -func Warning(v ...interface{}) { - if loggerLevel >= WarningLevel { - log.Println(v...) - } -} - -func Warningf(format string, v ...interface{}) { - if loggerLevel >= WarningLevel { - log.Printf(format, v...) - } -} - -func Debug(v ...interface{}) { - if loggerLevel >= DebugLevel { - log.Println(v...) - } -} - -func Debugf(format string, v ...interface{}) { - if loggerLevel >= DebugLevel { - log.Printf(format, v...) - } -} diff --git a/main.go b/main.go index ecf9011..94633d6 100644 --- a/main.go +++ b/main.go @@ -1,28 +1,290 @@ package main import ( - "log" + "encoding/json" + "io" + "log/slog" + "math/rand" "net/http" + "os" + "path/filepath" + "strconv" + "strings" + "text/template" + "time" - "git.andreafazzi.eu/andrea/probo/hasher/sha256" - "git.andreafazzi.eu/andrea/probo/logger" - "git.andreafazzi.eu/andrea/probo/store/memory" - "github.com/sirupsen/logrus" + "git.andreafazzi.eu/andrea/probo/lib/models" + "git.andreafazzi.eu/andrea/probo/lib/store" + "git.andreafazzi.eu/andrea/probo/lib/store/file" + "github.com/lmittmann/tint" ) -const port = "8080" +var ( + DefaultAssetDir = "assets" + DefaultDataDir = "data" + DefaultSessionDir = "sessions" + DefaultResponseDir = "responses" + DefaultTemplateDir = "templates" + DefaultStaticDir = "static" +) + +type Config struct { + SessionDir string + ResponseDir string + TemplateDir string + StaticDir string +} + +type ExamTemplateData struct { + *models.Exam + + SessionID string +} + +type Server struct { + config *Config + mux *http.ServeMux + + sessionFileStore *file.SessionFileStore + responseFileStore *file.ResponseFileStore +} + +func GetDefaultTemplateDir() string { + return filepath.Join(DefaultAssetDir, DefaultTemplateDir) +} + +func GetDefaultStaticDir() string { + return filepath.Join(DefaultAssetDir, DefaultStaticDir) +} + +func GetDefaultSessionDir() string { + return filepath.Join(DefaultDataDir, DefaultSessionDir) +} + +func GetDefaultResponseDir() string { + return filepath.Join(DefaultDataDir, DefaultResponseDir) +} + +func NewServer(config *Config) (*Server, error) { + _, err := os.Stat(config.SessionDir) + if err != nil { + return nil, err + } + + _, err = os.Stat(config.TemplateDir) + if err != nil { + return nil, err + } + + _, err = os.Stat(config.StaticDir) + if err != nil { + return nil, err + } + + sStore, err := file.NewSessionFileStore( + &file.FileStoreConfig[*models.Session, *store.SessionStore]{ + FilePathConfig: file.FilePathConfig{Dir: config.SessionDir, FilePrefix: "session", FileSuffix: ".json"}, + IndexDirFunc: file.DefaultIndexDirFunc[*models.Session, *store.SessionStore], + CreateEntityFunc: func() *models.Session { + return &models.Session{} + }, + }, + ) + if err != nil { + return nil, err + } + + rStore, err := file.NewResponseFileStore( + &file.FileStoreConfig[*models.Response, *store.ResponseStore]{ + FilePathConfig: file.FilePathConfig{Dir: config.ResponseDir, FilePrefix: "response", FileSuffix: ".json"}, + IndexDirFunc: file.DefaultIndexDirFunc[*models.Response, *store.ResponseStore], + CreateEntityFunc: func() *models.Response { + return &models.Response{} + }, + }, + ) + if err != nil { + return nil, err + } + + rStore.FilePathConfig = file.FilePathConfig{ + Dir: config.ResponseDir, + FilePrefix: "response", + FileSuffix: ".json", + } + + s := &Server{ + config, + http.NewServeMux(), + sStore, + rStore, + } + + s.mux.Handle("/static/", http.StripPrefix("/static", http.FileServer(http.Dir(config.StaticDir)))) + s.mux.HandleFunc("/create", s.createExamSessionHandler) + s.mux.HandleFunc("/responses/", s.getResponsesHandler) + s.mux.HandleFunc("/", s.getExamHandler) + + return s, nil +} + +func NewDefaultServer() (*Server, error) { + return NewServer(&Config{ + SessionDir: GetDefaultSessionDir(), + ResponseDir: GetDefaultResponseDir(), + TemplateDir: GetDefaultTemplateDir(), + StaticDir: GetDefaultStaticDir(), + }) +} + +func (s *Server) getResponsesHandler(w http.ResponseWriter, r *http.Request) { + result := make([]*models.Response, 0) + + urlParts := strings.Split(r.URL.Path, "/") + + sessionID := urlParts[2] + + if r.Method == "GET" { + session, err := s.sessionFileStore.Read(sessionID) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + for _, exam := range session.Exams { + responses := s.responseFileStore.ReadAll() + for _, r := range responses { + if r.ID == exam.ID { + result = append(result, r) + } + } + } + err = json.NewEncoder(w).Encode(result) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + } +} + +func (s *Server) createExamSessionHandler(w http.ResponseWriter, r *http.Request) { + session := new(models.Session) + + data, err := io.ReadAll(r.Body) + if err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + err = session.Unmarshal(data) + if err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + memorySession, err := s.sessionFileStore.Create(session) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + + err = json.NewEncoder(w).Encode(memorySession) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + + slog.Info("Received a new session", "session", memorySession) + +} + +func (s *Server) getExamHandler(w http.ResponseWriter, r *http.Request) { + urlParts := strings.Split(r.URL.Path, "/") + + sessionID := urlParts[1] + token := urlParts[2] + + session, err := s.sessionFileStore.Read(sessionID) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + + exam := session.Exams[token] + + if r.Method == "GET" { + w.Header().Set("Content-Type", "text/html") + + tplData, err := os.ReadFile(filepath.Join(GetDefaultTemplateDir(), "exam.tpl")) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + + } + tmpl := template.Must(template.New("exam").Parse(string(tplData))) + + err = tmpl.Execute(w, ExamTemplateData{exam, session.ID}) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + return + } + } + + if r.Method == "POST" { + err := r.ParseForm() + if err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + response := new(models.Response) + response.UniqueIDFunc = func() string { + return exam.GetID() + } + + response.Questions = make(map[string]string) + for qID, values := range r.Form { + for _, aID := range values { + response.Questions[qID] = aID + } + } + + _, err = s.responseFileStore.Create(response) + if err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + w.Write([]byte("

Thank you for your response.

")) + return + } + +} + +func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { + s.mux.ServeHTTP(w, r) +} + +func generateRandomID() string { + id := "" + for i := 0; i < 6; i++ { + id += strconv.Itoa(rand.Intn(9) + 1) + } + return id +} func main() { - logger.SetLevel(logger.DebugLevel) + slog.SetDefault(slog.New( + tint.NewHandler(os.Stdout, &tint.Options{ + Level: slog.LevelInfo, + TimeFormat: time.Kitchen, + }), + )) - server := NewProboCollectorServer( - memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ), - ) + server, err := NewDefaultServer() + if err != nil { + panic(err) + } - addr := "http://localhost:" + port - logrus.WithField("address", addr).Info("Probo Collector is up&running...") - - log.Fatal(http.ListenAndServe(":"+port, server)) + slog.Info("Probo server started.") + http.ListenAndServe(":8080", server) } diff --git a/server.go b/server.go deleted file mode 100644 index ff276bc..0000000 --- a/server.go +++ /dev/null @@ -1,150 +0,0 @@ -package main - -import ( - "encoding/json" - "io/ioutil" - "net/http" - - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/logger" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" - "github.com/julienschmidt/httprouter" -) - -type ProboCollectorServer struct { - store store.ProboCollectorStore - http.Handler -} - -func NewProboCollectorServer(store store.ProboCollectorStore) *ProboCollectorServer { - ps := new(ProboCollectorServer) - ps.store = store - - router := httprouter.New() - - router.GET("/quizzes", httprouter.Handle(ps.readAllQuizzesHandler)) - router.POST("/quizzes/create", httprouter.Handle(ps.createQuizHandler)) - router.PUT("/quizzes/update/:id", httprouter.Handle(ps.updateQuizHandler)) - - ps.Handler = logger.WithLogging(ps.jsonHeaderMiddleware(router)) - - return ps -} - -func (ps *ProboCollectorServer) jsonHeaderMiddleware(next http.Handler) http.Handler { - return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { - w.Header().Add("Content-Type", "application/json") - next.ServeHTTP(w, r) - }) -} - -func (ps *ProboCollectorServer) readAllQuizzesHandler(w http.ResponseWriter, r *http.Request, params httprouter.Params) { - response := new(client.ReadAllQuizResponse) - - quizzes, err := ps.readAllQuiz(w, r) - if err != nil { - response = &client.ReadAllQuizResponse{ - BaseResponse: client.BaseResponse{Status: "error", Message: err.Error()}, - Content: nil, - } - } else { - response = &client.ReadAllQuizResponse{ - BaseResponse: client.BaseResponse{Status: "success", Message: ""}, - Content: quizzes, - } - } - - w.WriteHeader(http.StatusOK) - json.NewEncoder(w).Encode(response) -} - -func (ps *ProboCollectorServer) createQuizHandler(w http.ResponseWriter, r *http.Request, params httprouter.Params) { - response := new(client.CreateQuizResponse) - - quiz, err := ps.createQuiz(w, r) - if err != nil { - response = &client.CreateQuizResponse{ - BaseResponse: client.BaseResponse{Status: "error", Message: err.Error()}, - Content: nil, - } - } - - response = &client.CreateQuizResponse{ - BaseResponse: client.BaseResponse{Status: "success", Message: ""}, - Content: quiz, - } - - w.WriteHeader(http.StatusAccepted) - json.NewEncoder(w).Encode(response) -} - -func (ps *ProboCollectorServer) updateQuizHandler(w http.ResponseWriter, r *http.Request, params httprouter.Params) { - response := new(client.UpdateQuizResponse) - - quiz, err := ps.updateQuiz(w, r, params.ByName("id")) - if err != nil { - response = &client.UpdateQuizResponse{ - BaseResponse: client.BaseResponse{Status: "error", Message: err.Error()}, - Content: nil, - } - } else { - response = &client.UpdateQuizResponse{ - BaseResponse: client.BaseResponse{Status: "success", Message: ""}, - Content: quiz, - } - } - - w.WriteHeader(http.StatusAccepted) - json.NewEncoder(w).Encode(response) -} - -func (ps *ProboCollectorServer) readAllQuiz(w http.ResponseWriter, r *http.Request) ([]*models.Quiz, error) { - quizzes, err := ps.store.ReadAllQuizzes() - if err != nil { - return nil, err - } - return quizzes, nil -} - -func (ps *ProboCollectorServer) updateQuiz(w http.ResponseWriter, r *http.Request, id string) (*models.Quiz, error) { - body, err := ioutil.ReadAll(r.Body) - if err != nil { - return nil, err - } - - updateQuizReq := new(client.CreateUpdateQuizRequest) - - err = json.Unmarshal(body, &updateQuizReq) - if err != nil { - return nil, err - } - - updatedQuiz, err := ps.store.UpdateQuiz(updateQuizReq, id) - if err != nil { - return nil, err - } - - return updatedQuiz, nil -} - -func (ps *ProboCollectorServer) createQuiz(w http.ResponseWriter, r *http.Request) (*models.Quiz, error) { - body, err := ioutil.ReadAll(r.Body) - if err != nil { - return nil, err - } - - createQuizReq := new(client.CreateUpdateQuizRequest) - - err = json.Unmarshal(body, &createQuizReq) - if err != nil { - return nil, err - } - - createdQuiz, err := ps.store.CreateQuiz(createQuizReq) - if err != nil { - return nil, err - } - - return createdQuiz, nil -} diff --git a/server/.gitignore b/server/.gitignore deleted file mode 100644 index a1e9e7d..0000000 --- a/server/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -server -data diff --git a/server/main.go b/server/main.go deleted file mode 100644 index 2f90bb8..0000000 --- a/server/main.go +++ /dev/null @@ -1,278 +0,0 @@ -package main - -import ( - "encoding/json" - "io" - "log" - "math/rand" - "net/http" - "os" - "path/filepath" - "strconv" - "strings" - "text/template" - - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" - "git.andreafazzi.eu/andrea/probo/store/file" -) - -var ( - DefaultDataDir = "data" - DefaultSessionDir = "sessions" - DefaultResponseDir = "responses" - DefaultTemplateDir = "templates" - DefaultStaticDir = "static" -) - -type Config struct { - SessionDir string - ResponseDir string - TemplateDir string - StaticDir string -} - -type ExamTemplateData struct { - *models.Exam - - SessionID string -} - -type Server struct { - config *Config - mux *http.ServeMux - - sessionFileStore *file.SessionFileStore - responseFileStore *file.ResponseFileStore -} - -func GetDefaultTemplateDir() string { - return DefaultTemplateDir -} - -func GetDefaultStaticDir() string { - return DefaultStaticDir -} - -func GetDefaultSessionDir() string { - return filepath.Join(DefaultDataDir, DefaultSessionDir) -} - -func GetDefaultResponseDir() string { - return filepath.Join(DefaultDataDir, DefaultResponseDir) -} - -func NewServer(config *Config) (*Server, error) { - _, err := os.Stat(config.SessionDir) - if err != nil { - return nil, err - } - - _, err = os.Stat(config.TemplateDir) - if err != nil { - return nil, err - } - - _, err = os.Stat(config.StaticDir) - if err != nil { - return nil, err - } - - sStore, err := file.NewSessionFileStore( - &file.FileStoreConfig[*models.Session, *store.SessionStore]{ - FilePathConfig: file.FilePathConfig{Dir: config.SessionDir, FilePrefix: "session", FileSuffix: ".json"}, - IndexDirFunc: file.DefaultIndexDirFunc[*models.Session, *store.SessionStore], - CreateEntityFunc: func() *models.Session { - return &models.Session{} - }, - }, - ) - if err != nil { - return nil, err - } - - rStore, err := file.NewResponseFileStore( - &file.FileStoreConfig[*models.Response, *store.ResponseStore]{ - FilePathConfig: file.FilePathConfig{Dir: config.ResponseDir, FilePrefix: "response", FileSuffix: ".json"}, - IndexDirFunc: file.DefaultIndexDirFunc[*models.Response, *store.ResponseStore], - CreateEntityFunc: func() *models.Response { - return &models.Response{} - }, - }, - ) - if err != nil { - return nil, err - } - - rStore.FilePathConfig = file.FilePathConfig{ - Dir: config.ResponseDir, - FilePrefix: "response", - FileSuffix: ".json", - } - - s := &Server{ - config, - http.NewServeMux(), - sStore, - rStore, - } - - s.mux.Handle("/static/", http.StripPrefix("/static", http.FileServer(http.Dir(config.StaticDir)))) - s.mux.HandleFunc("/create", s.createExamSessionHandler) - s.mux.HandleFunc("/responses/", s.getResponsesHandler) - s.mux.HandleFunc("/", s.getExamHandler) - - return s, nil -} - -func NewDefaultServer() (*Server, error) { - return NewServer(&Config{ - SessionDir: GetDefaultSessionDir(), - ResponseDir: GetDefaultResponseDir(), - TemplateDir: GetDefaultTemplateDir(), - StaticDir: GetDefaultStaticDir(), - }) -} - -func (s *Server) getResponsesHandler(w http.ResponseWriter, r *http.Request) { - result := make([]*models.Response, 0) - - urlParts := strings.Split(r.URL.Path, "/") - - sessionID := urlParts[2] - - if r.Method == "GET" { - session, err := s.sessionFileStore.Read(sessionID) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - for _, exam := range session.Exams { - responses := s.responseFileStore.ReadAll() - for _, r := range responses { - if r.ID == exam.ID { - result = append(result, r) - } - } - } - err = json.NewEncoder(w).Encode(result) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - } -} - -func (s *Server) createExamSessionHandler(w http.ResponseWriter, r *http.Request) { - session := new(models.Session) - - data, err := io.ReadAll(r.Body) - if err != nil { - http.Error(w, err.Error(), http.StatusBadRequest) - return - } - - err = session.Unmarshal(data) - if err != nil { - http.Error(w, err.Error(), http.StatusBadRequest) - return - } - - memorySession, err := s.sessionFileStore.Create(session) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - - err = json.NewEncoder(w).Encode(memorySession) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - -} - -func (s *Server) getExamHandler(w http.ResponseWriter, r *http.Request) { - urlParts := strings.Split(r.URL.Path, "/") - - sessionID := urlParts[1] - token := urlParts[2] - - session, err := s.sessionFileStore.Read(sessionID) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - - exam := session.Exams[token] - - if r.Method == "GET" { - w.Header().Set("Content-Type", "text/html") - - tplData, err := os.ReadFile(filepath.Join(GetDefaultTemplateDir(), "exam.tpl")) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - - } - tmpl := template.Must(template.New("exam").Parse(string(tplData))) - - err = tmpl.Execute(w, ExamTemplateData{exam, session.ID}) - if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) - return - } - } - - if r.Method == "POST" { - err := r.ParseForm() - if err != nil { - http.Error(w, err.Error(), http.StatusBadRequest) - return - } - - response := new(models.Response) - response.UniqueIDFunc = func() string { - return exam.GetID() - } - - response.Questions = make(map[string]string) - for qID, values := range r.Form { - for _, aID := range values { - response.Questions[qID] = aID - } - } - - _, err = s.responseFileStore.Create(response) - if err != nil { - http.Error(w, err.Error(), http.StatusBadRequest) - return - } - - w.Write([]byte("

Thank you for your response.

")) - return - } - -} - -func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { - s.mux.ServeHTTP(w, r) -} - -func generateRandomID() string { - id := "" - for i := 0; i < 6; i++ { - id += strconv.Itoa(rand.Intn(9) + 1) - } - return id -} - -func main() { - server, err := NewDefaultServer() - if err != nil { - panic(err) - } - - log.Println("Probo server started.") - http.ListenAndServe(":8080", server) -} diff --git a/server/payload.json b/server/payload.json deleted file mode 100644 index 97a93b4..0000000 --- a/server/payload.json +++ /dev/null @@ -1,170 +0,0 @@ -{ - "ID": "fe0a7ee0-f31a-413d-f123-ab5068bcaaaa", - "Name": "Test session", - "Exams": { - "111222": { - "id": "fe0a7ee0-f31a-413d-ba81-ab5068bc4c73", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "Participant": { - "ID": "1234", - "Firstname": "John", - "Lastname": "Smith", - "Token": 111222, - "Attributes": { - "class": "1 D LIN" - } - }, - "Quizzes": [ - { - "id": "0610939b-a1a3-4d0e-bbc4-2aae0e8ee4b9", - "created_at": "2023-11-27T17:51:53.910642221+01:00", - "updated_at": "0001-01-01T00:00:00Z", - "hash": "", - "question": { - "id": "98c0eec9-677f-464e-9e3e-864a859f29a3", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "text": "Question text with #tag1." - }, - "answers": [ - { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - { - "id": "74547724-b905-476f-8cfc-6ee633f92ef3", - "text": "Answer 2" - }, - { - "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", - "text": "Answer 3" - }, - { - "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", - "text": "Answer 4" - } - ], - "tags": [ - { - "CreatedAt": "0001-01-01T00:00:00Z", - "UpdatedAt": "0001-01-01T00:00:00Z", - "DeletedAt": null, - "name": "#tag1" - } - ], - "correct": { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - "CorrectPos": 0, - "type": 0 - }, - { - "id": "915818c4-b0ce-4efc-8def-7fc8d5fa7454", - "created_at": "2023-11-27T17:51:53.91077796+01:00", - "updated_at": "0001-01-01T00:00:00Z", - "hash": "", - "question": { - "id": "70793f0d-2855-4140-814e-40167464424b", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "text": "Another question text with #tag1." - }, - "answers": [ - { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - { - "id": "74547724-b905-476f-8cfc-6ee633f92ef3", - "text": "Answer 2" - }, - { - "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", - "text": "Answer 3" - }, - { - "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", - "text": "Answer 4" - } - ], - "tags": [ - { - "CreatedAt": "0001-01-01T00:00:00Z", - "UpdatedAt": "0001-01-01T00:00:00Z", - "DeletedAt": null, - "name": "#tag1" - } - ], - "correct": { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - "CorrectPos": 0, - "type": 0 - } - ] - } - }, - "333444": { - "id": "12345678-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "Participant": { - "ID": "5678", - "Firstname": "Jane", - "Lastname": "Doe", - "Token": 333444, - "Attributes": { - "class": "2 A SCI" - } - }, - "Quizzes": [ - { - "id": "22222222-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "hash": "", - "question": { - "id": "33333333-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "text": "Sample question text." - }, - "answers": [ - { - "id": "44444444-abcd-efgh-ijkl-9876543210ef", - "text": "Option 1" - }, - { - "id": "55555555-abcd-efgh-ijkl-9876543210ef", - "text": "Option 2" - }, - { - "id": "66666666-abcd-efgh-ijkl-9876543210ef", - "text": "Option 3" - }, - { - "id": "77777777-abcd-efgh-ijkl-9876543210ef", - "text": "Option 4" - } - ], - "tags": [ - { - "CreatedAt": "2023-12-01T12:00:00Z", - "UpdatedAt": "2023-12-01T12:00:00Z", - "DeletedAt": null, - "name": "#tag2" - } - ], - "correct": { - "id": "44444444-abcd-efgh-ijkl-9876543210ef", - "text": "Option 1" - }, - "CorrectPos": 0, - "type": 0 - } - ] - } -} diff --git a/server/server_test.go b/server/server_test.go deleted file mode 100644 index ea7f28a..0000000 --- a/server/server_test.go +++ /dev/null @@ -1,279 +0,0 @@ -package main - -import ( - "encoding/json" - "fmt" - "net/http" - "net/http/httptest" - "os" - "path/filepath" - "strings" - "testing" - - "git.andreafazzi.eu/andrea/probo/models" - "github.com/remogatto/prettytest" -) - -var examPayload = ` -{ - "ID": "fe0a7ee0-f31a-413d-f123-ab5068bcaaaa", - "Name": "Test session", - "Exams": { - "111222": { - "id": "fe0a7ee0-f31a-413d-ba81-ab5068bc4c73", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "Participant": { - "ID": "1234", - "Firstname": "John", - "Lastname": "Smith", - "Token": "111222", - "Attributes": { - "class": "1 D LIN" - } - }, - "Quizzes": [ - { - "id": "0610939b-a1a3-4d0e-bbc4-2aae0e8ee4b9", - "created_at": "2023-11-27T17:51:53.910642221+01:00", - "updated_at": "0001-01-01T00:00:00Z", - "hash": "", - "question": { - "id": "98c0eec9-677f-464e-9e3e-864a859f29a3", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "text": "Question text with #tag1." - }, - "answers": [ - { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - { - "id": "74547724-b905-476f-8cfc-6ee633f92ef3", - "text": "Answer 2" - }, - { - "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", - "text": "Answer 3" - }, - { - "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", - "text": "Answer 4" - } - ], - "tags": [ - { - "CreatedAt": "0001-01-01T00:00:00Z", - "UpdatedAt": "0001-01-01T00:00:00Z", - "DeletedAt": null, - "name": "#tag1" - } - ], - "correct": { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - "CorrectPos": 0, - "type": 0 - }, - { - "id": "915818c4-b0ce-4efc-8def-7fc8d5fa7454", - "created_at": "2023-11-27T17:51:53.91077796+01:00", - "updated_at": "0001-01-01T00:00:00Z", - "hash": "", - "question": { - "id": "70793f0d-2855-4140-814e-40167464424b", - "created_at": "0001-01-01T00:00:00Z", - "updated_at": "0001-01-01T00:00:00Z", - "text": "Another question text with #tag1." - }, - "answers": [ - { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - { - "id": "74547724-b905-476f-8cfc-6ee633f92ef3", - "text": "Answer 2" - }, - { - "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", - "text": "Answer 3" - }, - { - "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", - "text": "Answer 4" - } - ], - "tags": [ - { - "CreatedAt": "0001-01-01T00:00:00Z", - "UpdatedAt": "0001-01-01T00:00:00Z", - "DeletedAt": null, - "name": "#tag1" - } - ], - "correct": { - "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", - "text": "Answer 1" - }, - "CorrectPos": 0, - "type": 0 - } - ] - } - }, - "333444": { - "id": "12345678-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "Participant": { - "ID": "5678", - "Firstname": "Jane", - "Lastname": "Doe", - "Token": "333444", - "Attributes": { - "class": "2 A SCI" - } - }, - "Quizzes": [ - { - "id": "22222222-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "hash": "", - "question": { - "id": "33333333-abcd-efgh-ijkl-9876543210ef", - "created_at": "2023-12-01T12:00:00Z", - "updated_at": "2023-12-01T12:00:00Z", - "text": "Sample question text." - }, - "answers": [ - { - "id": "44444444-abcd-efgh-ijkl-9876543210ef", - "text": "Option 1" - }, - { - "id": "55555555-abcd-efgh-ijkl-9876543210ef", - "text": "Option 2" - }, - { - "id": "66666666-abcd-efgh-ijkl-9876543210ef", - "text": "Option 3" - }, - { - "id": "77777777-abcd-efgh-ijkl-9876543210ef", - "text": "Option 4" - } - ], - "tags": [ - { - "CreatedAt": "2023-12-01T12:00:00Z", - "UpdatedAt": "2023-12-01T12:00:00Z", - "DeletedAt": null, - "name": "#tag2" - } - ], - "correct": { - "id": "44444444-abcd-efgh-ijkl-9876543210ef", - "text": "Option 1" - }, - "CorrectPos": 0, - "type": 0 - } - ] - } -} -` - -type serverTestSuite struct { - prettytest.Suite -} - -func TestRunner(t *testing.T) { - prettytest.Run( - t, - new(serverTestSuite), - ) -} - -func (t *serverTestSuite) TestCreate() { - - DefaultDataDir = "testdata" - - s, err := NewDefaultServer() - t.Nil(err) - - if !t.Failed() { - request, _ := http.NewRequest(http.MethodPost, "/create", strings.NewReader(examPayload)) - response := httptest.NewRecorder() - - handler := http.HandlerFunc(s.createExamSessionHandler) - - handler.ServeHTTP(response, request) - - t.Equal(http.StatusOK, response.Code) - - if !t.Failed() { - var session *models.Session - - err := json.Unmarshal(response.Body.Bytes(), &session) - t.Nil(err) - - path := filepath.Join(GetDefaultSessionDir(), "session_fe0a7ee0-f31a-413d-f123-ab5068bcaaaa.json") - - _, err = os.Stat(path) - t.Nil(err) - - defer os.Remove(path) - - t.Equal("fe0a7ee0-f31a-413d-f123-ab5068bcaaaa", session.ID) - - } - } -} - -func (t *serverTestSuite) TestRead() { - - DefaultDataDir = "testdata" - - s, err := NewDefaultServer() - t.Nil(err) - - if !t.Failed() { - request, _ := http.NewRequest(http.MethodPost, "/create", strings.NewReader(examPayload)) - response := httptest.NewRecorder() - - handler := http.HandlerFunc(s.createExamSessionHandler) - - handler.ServeHTTP(response, request) - - t.Equal(http.StatusOK, response.Code) - - if !t.Failed() { - var session *models.Session - - err := json.Unmarshal(response.Body.Bytes(), &session) - t.Nil(err) - - path := filepath.Join(GetDefaultSessionDir(), "session_fe0a7ee0-f31a-413d-f123-ab5068bcaaaa.json") - _, err = os.Stat(path) - t.Nil(err) - - if !t.Failed() { - defer os.RemoveAll(path) - - request, _ := http.NewRequest(http.MethodGet, fmt.Sprintf("/%s/%s", session.ID, "111222"), nil) - response := httptest.NewRecorder() - - handler := http.HandlerFunc(s.getExamHandler) - - handler.ServeHTTP(response, request) - - t.Equal(http.StatusOK, response.Code) - - } - } - } -} diff --git a/server_integration_test.go b/server_integration_test.go deleted file mode 100644 index c8dee7c..0000000 --- a/server_integration_test.go +++ /dev/null @@ -1,201 +0,0 @@ -package main - -import ( - "encoding/json" - "fmt" - "net/http" - "net/http/httptest" - "reflect" - "strings" - - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/hasher/sha256" - "git.andreafazzi.eu/andrea/probo/store/memory" - "github.com/remogatto/prettytest" -) - -type integrationTestSuite struct { - prettytest.Suite -} - -func (t *integrationTestSuite) TestQuizCreateAndReadAll() { - server := NewProboCollectorServer( - memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ), - ) - - // POST a new question using a JSON payload - - payload := ` -{ - "question": {"text": "Question 1"}, - "answers": [ - {"text": "Text of the answer 1", "correct": true}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3"}, - {"text": "Text of the answer 4"} - ] -} -` - createQuizResponse, err := t.createQuiz(server, payload) - t.True(err == nil, "Response should be decoded properly") - - if !t.Failed() { - t.Equal("success", createQuizResponse.Status) - t.Equal("Question 1", createQuizResponse.Content.Question.Text) - t.Equal("Text of the answer 1", createQuizResponse.Content.Answers[0].Text) - t.Equal("Text of the answer 1", createQuizResponse.Content.Correct.Text) - - t.True(createQuizResponse.Content.ID != "", "Test ID should not be empty") - t.True(createQuizResponse.Content.Question.ID != "", "Question ID should not be empty") - t.True(createQuizResponse.Content.Answers[0].ID != "", "Answer ID should not be empty") - } - - readAllQuizResponse, err := t.readAllQuiz(server) - t.True(err == nil, "Response should be decoded properly") - - if !t.Failed() { - t.True(len(readAllQuizResponse.Content) == 1, "Length of returned tests should be 1") - t.Equal("Question 1", readAllQuizResponse.Content[0].Question.Text) - } -} - -func (t *integrationTestSuite) TestQuizCreateAndUpdate() { - server := NewProboCollectorServer( - memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ), - ) - - // POST a new question using a JSON payload - - payload := ` -{ - "question": {"text": "Question 1"}, - "answers": [ - {"text": "Text of the answer 1", "correct": true}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3"}, - {"text": "Text of the answer 4"} - ] -} -` - createQuizResponse, err := t.createQuiz(server, payload) - t.True(err == nil, "Response should be decoded properly") - - if !t.Failed() { - payload = ` -{ - "question": {"text": "Updated Question 1"}, - "answers": [ - {"text": "Text of the answer 1"}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3", "correct": true}, - {"text": "Text of the answer 4"} - ] -} - -` - updateQuizResponse, err := t.updateQuiz(server, payload, createQuizResponse.Content.ID) - t.True(err == nil, "Response should be decoded properly") - - if !t.Failed() { - t.Equal("Updated Question 1", updateQuizResponse.Content.Question.Text) - t.Equal("Text of the answer 3", updateQuizResponse.Content.Correct.Text) - } - - } -} - -func (t *integrationTestSuite) TestUpdateNotExistentQuiz() { - server := NewProboCollectorServer( - memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ), - ) - - payload := "" - r, err := t.updateQuiz(server, payload, "1234") - - t.True(err == nil, fmt.Sprintf("The operation should not return an error: %v", err)) - t.Equal("error", r.Status) -} - -func (t *integrationTestSuite) TestCatchDuplicateQuiz() { - server := NewProboCollectorServer( - memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ), - ) - - // POST a new question using a JSON payload - - payload := ` -{ - "question": {"text": "Question 1"}, - "answers": [ - {"text": "Text of the answer 1", "correct": true}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3"}, - {"text": "Text of the answer 4"} - ] -} -` - quiz1, err := t.createQuiz(server, payload) - - t.True(err == nil, fmt.Sprintf("Create quiz should not raise an error: %v", err)) - - quiz2, err := t.createQuiz(server, payload) - - t.True(err == nil, "Quizzes are duplicated, but the API should not return an error") - t.True(reflect.DeepEqual(quiz1, quiz2), "Quizzes shold be exactly the same") -} - -func (t *integrationTestSuite) createQuiz(server *ProboCollectorServer, payload string) (*client.CreateQuizResponse, error) { - request, _ := http.NewRequest(http.MethodPost, "/quizzes/create", strings.NewReader(payload)) - response := httptest.NewRecorder() - - server.ServeHTTP(response, request) - - decodedResponse := new(client.CreateQuizResponse) - - err := json.Unmarshal(response.Body.Bytes(), decodedResponse) - if err != nil { - return nil, err - } - - return decodedResponse, err -} - -func (t *integrationTestSuite) updateQuiz(server *ProboCollectorServer, payload string, id string) (*client.UpdateQuizResponse, error) { - request, _ := http.NewRequest(http.MethodPut, "/quizzes/update/"+id, strings.NewReader(payload)) - response := httptest.NewRecorder() - - server.ServeHTTP(response, request) - - decodedResponse := new(client.UpdateQuizResponse) - - err := json.Unmarshal(response.Body.Bytes(), decodedResponse) - if err != nil { - return decodedResponse, err - } - - return decodedResponse, err -} - -func (t *integrationTestSuite) readAllQuiz(server *ProboCollectorServer) (*client.ReadAllQuizResponse, error) { - request, _ := http.NewRequest(http.MethodGet, "/quizzes", nil) - response := httptest.NewRecorder() - - server.ServeHTTP(response, request) - - decodedResponse := new(client.ReadAllQuizResponse) - - err := json.Unmarshal(response.Body.Bytes(), decodedResponse) - if err != nil { - return nil, err - } - - return decodedResponse, err -} diff --git a/server_test.go b/server_test.go index af9663d..fe3b0c5 100644 --- a/server_test.go +++ b/server_test.go @@ -3,149 +3,287 @@ package main import ( "encoding/json" "fmt" - "io" + "log/slog" "net/http" "net/http/httptest" - "reflect" + "os" + "path/filepath" "strings" "testing" + "time" - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/logger" - "git.andreafazzi.eu/andrea/probo/models" + "git.andreafazzi.eu/andrea/probo/lib/models" + "github.com/lmittmann/tint" "github.com/remogatto/prettytest" ) -type testSuite struct { +var examPayload = ` +{ + "ID": "fe0a7ee0-f31a-413d-f123-ab5068bcaaaa", + "Name": "Test session", + "Exams": { + "111222": { + "id": "fe0a7ee0-f31a-413d-ba81-ab5068bc4c73", + "created_at": "0001-01-01T00:00:00Z", + "updated_at": "0001-01-01T00:00:00Z", + "Participant": { + "ID": "1234", + "Firstname": "John", + "Lastname": "Smith", + "Token": "111222", + "Attributes": { + "class": "1 D LIN" + } + }, + "Quizzes": [ + { + "id": "0610939b-a1a3-4d0e-bbc4-2aae0e8ee4b9", + "created_at": "2023-11-27T17:51:53.910642221+01:00", + "updated_at": "0001-01-01T00:00:00Z", + "hash": "", + "question": { + "id": "98c0eec9-677f-464e-9e3e-864a859f29a3", + "created_at": "0001-01-01T00:00:00Z", + "updated_at": "0001-01-01T00:00:00Z", + "text": "Question text with #tag1." + }, + "answers": [ + { + "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", + "text": "Answer 1" + }, + { + "id": "74547724-b905-476f-8cfc-6ee633f92ef3", + "text": "Answer 2" + }, + { + "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", + "text": "Answer 3" + }, + { + "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", + "text": "Answer 4" + } + ], + "tags": [ + { + "CreatedAt": "0001-01-01T00:00:00Z", + "UpdatedAt": "0001-01-01T00:00:00Z", + "DeletedAt": null, + "name": "#tag1" + } + ], + "correct": { + "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", + "text": "Answer 1" + }, + "CorrectPos": 0, + "type": 0 + }, + { + "id": "915818c4-b0ce-4efc-8def-7fc8d5fa7454", + "created_at": "2023-11-27T17:51:53.91077796+01:00", + "updated_at": "0001-01-01T00:00:00Z", + "hash": "", + "question": { + "id": "70793f0d-2855-4140-814e-40167464424b", + "created_at": "0001-01-01T00:00:00Z", + "updated_at": "0001-01-01T00:00:00Z", + "text": "Another question text with #tag1." + }, + "answers": [ + { + "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", + "text": "Answer 1" + }, + { + "id": "74547724-b905-476f-8cfc-6ee633f92ef3", + "text": "Answer 2" + }, + { + "id": "96c1a8ee-c50c-4ebc-89e4-9f3ca356adbd", + "text": "Answer 3" + }, + { + "id": "16c4b95e-64ce-4666-8cbe-b66fa59eb23b", + "text": "Answer 4" + } + ], + "tags": [ + { + "CreatedAt": "0001-01-01T00:00:00Z", + "UpdatedAt": "0001-01-01T00:00:00Z", + "DeletedAt": null, + "name": "#tag1" + } + ], + "correct": { + "id": "1ab5ff1f-74c8-4efc-abdc-d03a3640f3bc", + "text": "Answer 1" + }, + "CorrectPos": 0, + "type": 0 + } + ] + } + }, + "333444": { + "id": "12345678-abcd-efgh-ijkl-9876543210ef", + "created_at": "2023-12-01T12:00:00Z", + "updated_at": "2023-12-01T12:00:00Z", + "Participant": { + "ID": "5678", + "Firstname": "Jane", + "Lastname": "Doe", + "Token": "333444", + "Attributes": { + "class": "2 A SCI" + } + }, + "Quizzes": [ + { + "id": "22222222-abcd-efgh-ijkl-9876543210ef", + "created_at": "2023-12-01T12:00:00Z", + "updated_at": "2023-12-01T12:00:00Z", + "hash": "", + "question": { + "id": "33333333-abcd-efgh-ijkl-9876543210ef", + "created_at": "2023-12-01T12:00:00Z", + "updated_at": "2023-12-01T12:00:00Z", + "text": "Sample question text." + }, + "answers": [ + { + "id": "44444444-abcd-efgh-ijkl-9876543210ef", + "text": "Option 1" + }, + { + "id": "55555555-abcd-efgh-ijkl-9876543210ef", + "text": "Option 2" + }, + { + "id": "66666666-abcd-efgh-ijkl-9876543210ef", + "text": "Option 3" + }, + { + "id": "77777777-abcd-efgh-ijkl-9876543210ef", + "text": "Option 4" + } + ], + "tags": [ + { + "CreatedAt": "2023-12-01T12:00:00Z", + "UpdatedAt": "2023-12-01T12:00:00Z", + "DeletedAt": null, + "name": "#tag2" + } + ], + "correct": { + "id": "44444444-abcd-efgh-ijkl-9876543210ef", + "text": "Option 1" + }, + "CorrectPos": 0, + "type": 0 + } + ] + } +} +` + +type serverTestSuite struct { prettytest.Suite } -type StubTestHubCollectorStore struct { - tests []*models.Quiz -} - -func (store *StubTestHubCollectorStore) CreateQuiz(test *client.CreateUpdateQuizRequest) (*models.Quiz, error) { - return nil, nil -} - -func (store *StubTestHubCollectorStore) UpdateQuiz(quiz *client.CreateUpdateQuizRequest, id string) (*models.Quiz, error) { - store.tests[0].Question.Text = quiz.Question.Text - - return store.tests[0], nil -} - -func (store *StubTestHubCollectorStore) ReadAllQuizzes() ([]*models.Quiz, error) { - return store.tests, nil -} - func TestRunner(t *testing.T) { + slog.SetDefault(slog.New( + tint.NewHandler(os.Stderr, &tint.Options{ + Level: slog.LevelError, + TimeFormat: time.Kitchen, + }), + )) + prettytest.Run( t, - new(testSuite), - new(integrationTestSuite), + new(serverTestSuite), ) } -func (t *testSuite) BeforeAll() { - logger.SetLevel(logger.Disabled) -} +func (t *serverTestSuite) TestCreate() { -func (t *testSuite) TestReadAllQuizzes() { - expectedResult := &client.ReadAllQuizResponse{ - BaseResponse: client.BaseResponse{Status: "success"}, - Content: []*models.Quiz{ - { - Question: &models.Question{ID: "1", Text: "Question 1"}, - Answers: []*models.Answer{{}, {}, {}}, - }, - }, - } + DefaultDataDir = "testdata" - store := &StubTestHubCollectorStore{[]*models.Quiz{ - { - Question: &models.Question{ID: "1", Text: "Question 1"}, - Answers: []*models.Answer{{}, {}, {}}, - }, - }} - - server := NewProboCollectorServer(store) - - request, _ := http.NewRequest(http.MethodGet, "/quizzes", nil) - response := httptest.NewRecorder() - - server.ServeHTTP(response, request) - - result := getResponse(response.Body) - - t.Equal("application/json", response.Header().Get("Content-Type")) - t.True(testsAreEqual(result, expectedResult)) - - t.Equal(http.StatusOK, response.Code) -} - -func (t *testSuite) TestUpdateQuiz() { - expectedResponse := &client.UpdateQuizResponse{ - BaseResponse: client.BaseResponse{Status: "success"}, - Content: &models.Quiz{ - Question: &models.Question{ID: "1", Text: "Updated Question 1"}, - Answers: []*models.Answer{{}, {}, {}}, - }, - } - - store := &StubTestHubCollectorStore{[]*models.Quiz{ - { - Question: &models.Question{ID: "1", Text: "Question 1"}, - Answers: []*models.Answer{{}, {}, {}}, - }, - }} - - server := NewProboCollectorServer(store) - - payload := ` -{ - "question": {"text": "Updated Question 1"}, - "answers": [ - {"text": "Text of the answer 1", "correct": true}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3"}, - {"text": "Text of the answer 4"} - ] -} -` - request, _ := http.NewRequest(http.MethodPut, "/quizzes/update/1", strings.NewReader(payload)) - response := httptest.NewRecorder() - - server.ServeHTTP(response, request) - - result, err := decodeUpdateQuizResponse(response.Body) - - t.True(err == nil, fmt.Sprintf("Response should be decoded without errors: %v", err)) + s, err := NewDefaultServer() + t.Nil(err) if !t.Failed() { - t.True(result.Status == expectedResponse.Status) - t.True(reflect.DeepEqual(result, expectedResponse)) - t.Equal("application/json", response.Header().Get("Content-Type")) - t.Equal(http.StatusAccepted, response.Code) + request, _ := http.NewRequest(http.MethodPost, "/create", strings.NewReader(examPayload)) + response := httptest.NewRecorder() + + handler := http.HandlerFunc(s.createExamSessionHandler) + + handler.ServeHTTP(response, request) + + t.Equal(http.StatusOK, response.Code) + + if !t.Failed() { + var session *models.Session + + err := json.Unmarshal(response.Body.Bytes(), &session) + t.Nil(err) + + path := filepath.Join(GetDefaultSessionDir(), "session_fe0a7ee0-f31a-413d-f123-ab5068bcaaaa.json") + + _, err = os.Stat(path) + t.Nil(err) + + defer os.Remove(path) + + t.Equal("fe0a7ee0-f31a-413d-f123-ab5068bcaaaa", session.ID) + + } } } -func getResponse(body io.Reader) (response *client.ReadAllQuizResponse) { - err := json.NewDecoder(body).Decode(&response) - if err != nil { - panic(fmt.Errorf("Unable to parse response from server %q: %v", body, err)) +func (t *serverTestSuite) TestRead() { + + DefaultDataDir = "testdata" + + s, err := NewDefaultServer() + t.Nil(err) + + if !t.Failed() { + request, _ := http.NewRequest(http.MethodPost, "/create", strings.NewReader(examPayload)) + response := httptest.NewRecorder() + + handler := http.HandlerFunc(s.createExamSessionHandler) + + handler.ServeHTTP(response, request) + + t.Equal(http.StatusOK, response.Code) + + if !t.Failed() { + var session *models.Session + + err := json.Unmarshal(response.Body.Bytes(), &session) + t.Nil(err) + + path := filepath.Join(GetDefaultSessionDir(), "session_fe0a7ee0-f31a-413d-f123-ab5068bcaaaa.json") + _, err = os.Stat(path) + t.Nil(err) + + if !t.Failed() { + defer os.RemoveAll(path) + + request, _ := http.NewRequest(http.MethodGet, fmt.Sprintf("/%s/%s", session.ID, "111222"), nil) + response := httptest.NewRecorder() + + handler := http.HandlerFunc(s.getExamHandler) + + handler.ServeHTTP(response, request) + + t.Equal(http.StatusOK, response.Code) + + } + } } - - return -} - -func decodeUpdateQuizResponse(body io.Reader) (response *client.UpdateQuizResponse, err error) { - err = json.NewDecoder(body).Decode(&response) - if err != nil { - return nil, fmt.Errorf("Unable to parse the response %q from the server: %v", body, err) - } - return -} - -func testsAreEqual(got, want *client.ReadAllQuizResponse) bool { - return reflect.DeepEqual(got, want) } diff --git a/store/db/db.go b/store/db/db.go deleted file mode 100644 index 0247063..0000000 --- a/store/db/db.go +++ /dev/null @@ -1,79 +0,0 @@ -package db - -import ( - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/models" - "git.andreafazzi.eu/andrea/probo/store" - "github.com/glebarez/sqlite" - "github.com/google/uuid" - "gorm.io/gorm" -) - -type DBProboCollectorStore struct { - Path string - - db *gorm.DB - si store.ProboCollectorStore -} - -func NewDBProboCollectorStore(path string, s store.ProboCollectorStore) (*DBProboCollectorStore, error) { - var err error - - store := new(DBProboCollectorStore) - - store.db, err = gorm.Open(sqlite.Open(path), &gorm.Config{}) - if err != nil { - return nil, err - } - - err = store.db.AutoMigrate( - &models.Question{}, - &models.Answer{}, - &models.Quiz{}, - &models.Collection{}, - &models.Exam{}, - &models.Participant{}, - ) - if err != nil { - return nil, err - } - - store.si = s - - return store, nil -} - -func (s *DBProboCollectorStore) CreateExam(r *client.CreateUpdateExamRequest) (*models.Exam, error) { - exam := new(models.Exam) - - exam.ID = uuid.New().String() - exam.Name = r.Name - exam.Description = r.Description - - collection, err := s.si.ReadCollectionByID(r.CollectionID) - if err != nil { - return nil, err - } - - exam.Collection = collection - - result := s.db.Create(exam) - if result.Error != nil { - return nil, result.Error - } - - return exam, nil -} - -func (s *DBProboCollectorStore) ReadExamByID(r *client.ReadExamByIDRequest) (*models.Exam, error) { - exam := &models.Exam{ - ID: r.ID, - } - - s.db.First(&exam) - if err := s.db.Error; err != nil { - return nil, err - } - - return exam, nil -} diff --git a/store/db/db_test.go b/store/db/db_test.go deleted file mode 100644 index e64ffbd..0000000 --- a/store/db/db_test.go +++ /dev/null @@ -1,76 +0,0 @@ -package db - -import ( - "os" - "testing" - - "git.andreafazzi.eu/andrea/probo/client" - "git.andreafazzi.eu/andrea/probo/hasher/sha256" - "git.andreafazzi.eu/andrea/probo/store/memory" - "github.com/remogatto/prettytest" -) - -type dbTestSuite struct { - prettytest.Suite -} - -func TestRunner(t *testing.T) { - prettytest.Run( - t, - new(dbTestSuite), - ) -} - -func (t *dbTestSuite) TestCreateExam() { - memStore := memory.NewMemoryProboCollectorStore( - sha256.NewDefault256Hasher(sha256.DefaultSHA256HashingFn), - ) - memStore.CreateQuiz( - &client.CreateUpdateQuizRequest{ - Quiz: &client.Quiz{ - Question: &client.Question{Text: "Newly created question text with #tag1."}, - Answers: []*client.Answer{ - {Text: "Answer 1", Correct: true}, - {Text: "Answer 2", Correct: false}, - {Text: "Answer 3", Correct: false}, - {Text: "Answer 4", Correct: false}, - }, - }, - }) - - store, err := NewDBProboCollectorStore("testdata/test.sqlite", memStore) - defer os.Remove("testdata/test.sqlite") - - t.Nil(err) - - if !t.Failed() { - collection, err := memStore.CreateCollection(&client.CreateUpdateCollectionRequest{ - Collection: &client.Collection{ - Name: "Collection name", - Query: "#tag1", - }, - }) - - t.Nil(err) - - if !t.Failed() { - exam, err := store.CreateExam(&client.CreateUpdateExamRequest{ - Exam: &client.Exam{ - Name: "Exam", - Description: "Exam description", - CollectionID: collection.ID, - }, - }) - - t.Nil(err) - if !t.Failed() { - t.Not(t.Nil(exam)) - examFromDb, err := store.ReadExamByID(&client.ReadExamByIDRequest{ID: exam.ID}) - t.Nil(err) - if !t.Failed() { - t.Equal(examFromDb.ID, exam.ID) - } - } - } - } -} diff --git a/server/testdata/responses/README b/testdata/responses/README similarity index 100% rename from server/testdata/responses/README rename to testdata/responses/README diff --git a/server/testdata/sessions/README b/testdata/sessions/README similarity index 100% rename from server/testdata/sessions/README rename to testdata/sessions/README diff --git a/tests/hurl/create_new_quiz.hurl b/tests/hurl/create_new_quiz.hurl deleted file mode 100644 index 38bf68a..0000000 --- a/tests/hurl/create_new_quiz.hurl +++ /dev/null @@ -1,10 +0,0 @@ -POST http://localhost:8080/quizzes/create -{ - "question": {"text": "Text of Question 1"}, - "answers": [ - {"text": "Text of the answer 1", "correct": true}, - {"text": "Text of the answer 2"}, - {"text": "Text of the answer 3"}, - {"text": "Text of the answer 4"} - ] -} diff --git a/tests/hurl/read_all_quiz.hurl b/tests/hurl/read_all_quiz.hurl deleted file mode 100644 index 60ba47b..0000000 --- a/tests/hurl/read_all_quiz.hurl +++ /dev/null @@ -1 +0,0 @@ -GET http://localhost:8080/quizzes