summaryrefslogtreecommitdiffhomepage
path: root/AGENTS.md
diff options
context:
space:
mode:
authorAiden Cline <[email protected]>2026-01-25 17:54:17 -0500
committerAiden Cline <[email protected]>2026-01-25 17:54:17 -0500
commitf0830a74bb36d5836c4ca4e20e406ad541c262ff (patch)
tree13225da9c665f14773618d2986494ba6cd17b2a9 /AGENTS.md
parent57532326f7b3526348b14e82bb61ecd41ac7d480 (diff)
downloadopencode-f0830a74bb36d5836c4ca4e20e406ad541c262ff.tar.gz
opencode-f0830a74bb36d5836c4ca4e20e406ad541c262ff.zip
ignore: update AGENTS.md
Diffstat (limited to 'AGENTS.md')
-rw-r--r--AGENTS.md11
1 files changed, 8 insertions, 3 deletions
diff --git a/AGENTS.md b/AGENTS.md
index 6619861c2..c157fa32d 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -11,7 +11,7 @@
- Prefer single word variable names where possible
- Use Bun APIs when possible, like `Bun.file()`
-# Avoid let statements
+### Avoid let statements
We don't like `let` statements, especially combined with if/else statements.
Prefer `const`.
@@ -31,7 +31,7 @@ if (condition) foo = 1
else foo = 2
```
-# Avoid else statements
+### Avoid else statements
Prefer early returns or using an `iife` to avoid else statements.
@@ -53,7 +53,7 @@ function foo() {
}
```
-# Prefer single word naming
+### Prefer single word naming
Try your best to find a single word name for your variables, functions, etc.
Only use multiple words if you cannot.
@@ -73,3 +73,8 @@ const fooBar = 1
const barBaz = 2
const bazFoo = 3
```
+
+## Testing
+
+You MUST avoid using `mocks` as much as possible.
+Tests MUST test actual implementation, do not duplicate logic into a test.