- Notifications
You must be signed in to change notification settings - Fork928
feat: generate golden files for notification templates#14537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Merged
Uh oh!
There was an error while loading.Please reload this page.
Merged
Changes fromall commits
Commits
Show all changes
24 commits Select commitHold shift + click to select a range
b2523b1
WIP
mtojek9559138
WIP2
mtojek39d80eb
Template body
mtojekd9fef24
fmt
mtojek994f484
adjust payload
mtojekc55a688
fix
mtojek796da33
no index
mtojekc23da28
fix range
mtojek53dc29f
fix: base_url
mtojek1753beb
test
mtojeke200056
WIP
mtojek1118d67
WIP
mtojek7c7e0f9
WIP
mtojekca0d9ee
s/bobby/Bobby/g
mtojekd91742c
gen
mtojek9fe5def
back to false
mtojek4d95288
fix
mtojekb12dcfc
Address PR feedback
mtojek412e9b2
db=ci
mtojek419c56a
golden
mtojek14ad9e8
fix
mtojek7587abc
split
mtojekf537d26
done
mtojek47c387b
fmt
mtojekFile filter
Filter by extension
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
59 changes: 44 additions & 15 deletionscoderd/notifications/notifications_test.go
This file contains hidden or 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
3 changes: 3 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateTemplateDeleted-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby | ||
The template **bobby-template** was deleted by **rob**. |
1 change: 1 addition & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateTemplateDeleted-title.md.golden
This file contains hidden or 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 @@ | ||
Template "bobby-template" deleted |
2 changes: 2 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountActivated-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
User account **bobby** has been activated. |
1 change: 1 addition & 0 deletions...rd/notifications/testdata/rendered-templates/TemplateUserAccountActivated-title.md.golden
This file contains hidden or 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 @@ | ||
User account "bobby" activated |
3 changes: 3 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountCreated-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
New user account **bobby** has been created. |
1 change: 1 addition & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountCreated-title.md.golden
This file contains hidden or 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 @@ | ||
User account "bobby" created |
3 changes: 3 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountDeleted-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
User account **bobby** has been deleted. |
1 change: 1 addition & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountDeleted-title.md.golden
This file contains hidden or 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 @@ | ||
User account "bobby" deleted |
2 changes: 2 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateUserAccountSuspended-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
User account **bobby** has been suspended. |
1 change: 1 addition & 0 deletions...rd/notifications/testdata/rendered-templates/TemplateUserAccountSuspended-title.md.golden
This file contains hidden or 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 @@ | ||
User account "bobby" suspended |
3 changes: 3 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateWorkspaceAutoUpdated-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby | ||
Your workspace **bobby-workspace** has been updated automatically to the latest template version (1.0). | ||
Reason for update: **template now includes catnip** |
1 change: 1 addition & 0 deletions...rd/notifications/testdata/rendered-templates/TemplateWorkspaceAutoUpdated-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" updated automatically |
3 changes: 3 additions & 0 deletions...notifications/testdata/rendered-templates/TemplateWorkspaceAutobuildFailed-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby | ||
Automatic build of your workspace **bobby-workspace** failed. | ||
The specified reason was "**autostart**". |
1 change: 1 addition & 0 deletions...otifications/testdata/rendered-templates/TemplateWorkspaceAutobuildFailed-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" autobuild failed |
4 changes: 4 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateWorkspaceDeleted-body.md.golden
This file contains hidden or 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,4 @@ | ||
Hi Bobby | ||
Your workspace **bobby-workspace** was deleted. | ||
The specified reason was "**autodeleted due to dormancy (autobuild)**". |
1 change: 1 addition & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateWorkspaceDeleted-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" deleted |
5 changes: 5 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateWorkspaceDormant-body.md.golden
This file contains hidden or 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,5 @@ | ||
Hi Bobby | ||
Your workspace **bobby-workspace** has been marked as [**dormant**](https://coder.com/docs/templates/schedule#dormancy-threshold-enterprise) because of breached the template's threshold for inactivity. | ||
Dormant workspaces are [automatically deleted](https://coder.com/docs/templates/schedule#dormancy-auto-deletion-enterprise) after 24 hours of inactivity. | ||
To prevent deletion, use your workspace with the link below. |
1 change: 1 addition & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateWorkspaceDormant-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" marked as dormant |
4 changes: 4 additions & 0 deletions...tifications/testdata/rendered-templates/TemplateWorkspaceManualBuildFailed-body.md.golden
This file contains hidden or 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,4 @@ | ||
Hi Bobby, | ||
A manual build of the workspace **bobby-workspace** using the template **bobby-template** failed (version: **bobby-template-version**). | ||
The workspace build was initiated by **joe**. |
1 change: 1 addition & 0 deletions...ifications/testdata/rendered-templates/TemplateWorkspaceManualBuildFailed-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" manual build failed |
4 changes: 4 additions & 0 deletions...tifications/testdata/rendered-templates/TemplateWorkspaceMarkedForDeletion-body.md.golden
This file contains hidden or 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,4 @@ | ||
Hi Bobby | ||
Your workspace **bobby-workspace** has been marked for **deletion** after 24 hours of [dormancy](https://coder.com/docs/templates/schedule#dormancy-auto-deletion-enterprise) because of template updated to new dormancy policy. | ||
To prevent deletion, use your workspace with the link below. |
1 change: 1 addition & 0 deletions...ifications/testdata/rendered-templates/TemplateWorkspaceMarkedForDeletion-title.md.golden
This file contains hidden or 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 @@ | ||
Workspace "bobby-workspace" marked for deletion |
2 changes: 2 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateYourAccountActivated-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
Your account **bobby** has been activated. |
1 change: 1 addition & 0 deletions...rd/notifications/testdata/rendered-templates/TemplateYourAccountActivated-title.md.golden
This file contains hidden or 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 @@ | ||
Your account "bobby" has been activated |
2 changes: 2 additions & 0 deletionscoderd/notifications/testdata/rendered-templates/TemplateYourAccountSuspended-body.md.golden
This file contains hidden or 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 @@ | ||
Hi Bobby, | ||
Your account **bobby** has been suspended. |
1 change: 1 addition & 0 deletions...rd/notifications/testdata/rendered-templates/TemplateYourAccountSuspended-title.md.golden
This file contains hidden or 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 @@ | ||
Your account "bobby" has been suspended |
Oops, something went wrong.
Uh oh!
There was an error while loading.Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.