-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #215 from noir-cr/dev
Release v0.12.0
- Loading branch information
Showing
65 changed files
with
995 additions
and
252 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
name: Crystal Build | ||
|
||
on: | ||
push: | ||
branches: [ "main", "dev" ] | ||
pull_request: | ||
branches: [ "main", "dev" ] | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
name: Crystal Lint | ||
|
||
on: | ||
push: | ||
pull_request: | ||
branches: [ "main", "dev" ] | ||
|
||
jobs: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
name: Crystal Test | ||
|
||
on: | ||
push: | ||
branches: [ "main", "dev" ] | ||
pull_request: | ||
branches: [ "main", "dev" ] | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
name: noir | ||
version: 0.11.0 | ||
version: 0.12.0 | ||
|
||
authors: | ||
- hahwul <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
aHR0cHM6Ly93d3cuaGFod3VsLmNvbS90YWcvY3J5c3RhbC8= | ||
eyJ6YXAiOiJodHRwczovL3d3dy5oYWh3dWwuY29tL3RhZy96YXAvIn0= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"url": [ | ||
"https://www.hahwul.com/tag/security/", | ||
"https://www.hahwul.com/phoenix" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Main: https://www.hahwul.com/ | ||
About page: https://www.hahwul.com/about | ||
Wiki: https://www.hahwul.com/cullinan |
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
module github.com/hahwul/test-go-app | ||
|
||
go 1.20 | ||
|
||
require ( | ||
github.com/andybalholm/brotli v1.0.6 // indirect | ||
github.com/gofiber/fiber/v2 v2.51.0 // indirect | ||
github.com/google/uuid v1.5.0 // indirect | ||
github.com/klauspost/compress v1.17.4 // indirect | ||
github.com/mattn/go-colorable v0.1.13 // indirect | ||
github.com/mattn/go-isatty v0.0.20 // indirect | ||
github.com/mattn/go-runewidth v0.0.15 // indirect | ||
github.com/rivo/uniseg v0.4.4 // indirect | ||
github.com/valyala/bytebufferpool v1.0.0 // indirect | ||
github.com/valyala/fasthttp v1.51.0 // indirect | ||
github.com/valyala/tcplisten v1.0.0 // indirect | ||
golang.org/x/sys v0.15.0 // indirect | ||
) |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package main | ||
|
||
import ( | ||
"log" | ||
|
||
fiber "github.com/gofiber/fiber/v2" | ||
) | ||
|
||
func main() { | ||
app := fiber.New() | ||
|
||
// GET /api/register | ||
app.Get("/info", func(c *fiber.Ctx) error { | ||
msg := c.Query("sort") | ||
return c.SendString(msg) // => ✋ register | ||
}) | ||
|
||
app.Post("/update", func(c *fiber.Ctx) error { | ||
msg := "Hello, World!" | ||
c.Cookies("auth") | ||
c.FormValue("name") | ||
c.GetRespHeader("X-API-Key") | ||
c.Vary("Origin") | ||
return c.SendString(msg) // => ✋ register | ||
}) | ||
|
||
app.Get("/ws", websocket.New(func(c *websocket.Conn) { | ||
// Websocket logic | ||
})) | ||
|
||
app.Static("/", "/public") | ||
|
||
log.Fatal(app.Listen(":3000")) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -124,4 +124,8 @@ class FunctionalTester | |
test_analyze | ||
end | ||
end | ||
|
||
def app | ||
@app | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
require "../func_spec.cr" | ||
|
||
extected_endpoints = [ | ||
Endpoint.new("https://www.hahwul.com/", "GET"), | ||
Endpoint.new("https://www.hahwul.com/about", "GET"), | ||
Endpoint.new("https://www.hahwul.com/cullinan", "GET"), | ||
Endpoint.new("https://www.hahwul.com/phoenix", "GET"), | ||
Endpoint.new("https://www.hahwul.com/tag/security/", "GET"), | ||
Endpoint.new("https://www.hahwul.com/tag/crystal/", "GET"), | ||
Endpoint.new("https://www.hahwul.com/tag/zap/", "GET"), | ||
] | ||
|
||
tester = FunctionalTester.new("fixtures/file_based/", { | ||
:techs => 0, | ||
:endpoints => 7, | ||
}, extected_endpoints) | ||
|
||
tester.app.options[:url] = "https://www.hahwul.com" | ||
tester.test_all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
require "../func_spec.cr" | ||
|
||
extected_endpoints = [ | ||
Endpoint.new("/info", "GET", [ | ||
Param.new("sort", "", "query"), | ||
]), | ||
Endpoint.new("/update", "POST", [ | ||
Param.new("name", "", "form"), | ||
Param.new("auth", "", "cookie"), | ||
Param.new("X-API-Key", "", "header"), | ||
Param.new("Vary", "Origin", "header"), | ||
]), | ||
Endpoint.new("/secret.html", "GET"), | ||
Endpoint.new("/ws", "GET"), | ||
] | ||
|
||
FunctionalTester.new("fixtures/go_fiber/", { | ||
:techs => 1, | ||
:endpoints => 4, | ||
}, extected_endpoints).test_all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.