summaryrefslogtreecommitdiffstats
path: root/modules/log/console.go
diff options
context:
space:
mode:
authorsinguliere <35190819+singuliere@users.noreply.github.com>2022-02-25 10:20:50 +0100
committerGitHub <noreply@github.com>2022-02-25 17:20:50 +0800
commit49cab2b01fc40c04dbd847e12a76516ced6b29b5 (patch)
tree23e6321729410782e4f7f0e8a9758267d63057c2 /modules/log/console.go
parente4ef61ee0fc319c5329dcb8e6cd961bb297730d1 (diff)
downloadgitea-49cab2b01fc40c04dbd847e12a76516ced6b29b5.tar.gz
gitea-49cab2b01fc40c04dbd847e12a76516ced6b29b5.zip
migrations: add test for importing pull requests in gitea uploader (#18752)
* logs: add the buffer logger to inspect logs during testing Signed-off-by: Loïc Dachary <loic@dachary.org> * migrations: add test for importing pull requests in gitea uploader Signed-off-by: Loïc Dachary <loic@dachary.org> * for each git.OpenRepositoryCtx, call Close * Content is expected to return the content of the log * test for errors before defer Co-authored-by: Loïc Dachary <loic@dachary.org> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'modules/log/console.go')
-rw-r--r--modules/log/console.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/log/console.go b/modules/log/console.go
index 7ecdd5c3b8..8c78add474 100644
--- a/modules/log/console.go
+++ b/modules/log/console.go
@@ -66,6 +66,11 @@ func (log *ConsoleLogger) Init(config string) error {
return nil
}
+// Content returns the content accumulated in the content provider
+func (log *ConsoleLogger) Content() (string, error) {
+ return "", fmt.Errorf("not supported")
+}
+
// Flush when log should be flushed
func (log *ConsoleLogger) Flush() {
}