graph_test
Version, currently main branch1 version
- main branchlatestSep 26, 2023
github.com/jwoertink/graph_testing
No description declared in shard.yml.
Installation
# Add this to your shard.yml
dependencies:
graph_test:
github: jwoertink/graph_testing
branch: mainmain is a branch, not a release, so this tracks it rather than pinning a version.
Then run:
shards installshard.yml
- Crystal
1.9.2- Author
- Jeremy Woertink
- Target
appfrom src/graph_test.cr
Dependencies
Runtime Dependencies
- avram~> 1.0.0github: luckyframework/avram
- lucky~> 1.0.0github: luckyframework/lucky
- carbon~> 0.3.0github: luckyframework/carbon
- graphql*github: graphql-crystal/graphql
- lucky_env~> 0.1.4github: luckyframework/lucky_env
- lucky_task~> 0.1.1github: luckyframework/lucky_task
- carbon_sendgrid_adapter~> 0.3.0github: luckyframework/carbon_sendgrid_adapter
README
Graph testing
This is a simple default Lucky app that has the GraphQL shard added. I'm using this to do memory and load testing.
Setup
- Clone the repo
./script/setupshards build --release --production
Testing
Boot the app with ./bin/graph_test, and then you can use curl to test.
curl -H "Accept: application/json" "http://localhost:3000"
curl -XPOST -H "Accept: application/json" "http://localhost:3000/api/graphql" -d '{"operationName":"Posts","variables":{},"query":"query Posts { posts { title\n releasedAt} }"}'
To load test with wrk
wrk -c 10 -t 6 -d 5m "http://localhost:3000/"
wrk -c 10 -t 6 -d 5m -s script.lua "http://localhost:3000/api/graphql"
Heaptrack
You can install Heaptrack to test the memory.
Boot the app with heaptrack using heaptrack ./bin/graph_test. When it boots, you'll see a file
that's being written to.
Once you're done, you can stop the application, then use heaptrack_gui that_file.zst to view the
results
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This branch
- Branch
main- Seen
- Sep 26, 2023
- Crystal
1.9.2- Indexed
- yes
Dependents
No indexed shard depends on this one yet.
Repository
github.com/jwoertink/graph_testing
Metadata
- Created
- Aug 12, 2026
- Updated
- Aug 15, 2026
- Synced
- Aug 15, 2026
- Versions
- 1