mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-13 11:42:38 +03:00
test-js+test-web: Replace JSTestRunnerCounts with Test::Counts
This commit is contained in:
parent
bce1f956e7
commit
edb6ada3ef
Notes:
sideshowbarker
2024-07-18 21:06:35 +09:00
Author: https://github.com/linusg Commit: https://github.com/SerenityOS/serenity/commit/edb6ada3ef6 Pull-request: https://github.com/SerenityOS/serenity/pull/5931
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2020, Matthew Olsson <matthewcolsson@gmail.com>
|
||||
* Copyright (c) 2020, Linus Groh <mail@linusgroh.de>
|
||||
* Copyright (c) 2020-2021, Linus Groh <mail@linusgroh.de>
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -68,15 +68,6 @@ struct JSFileResult {
|
||||
Vector<String> logged_messages {};
|
||||
};
|
||||
|
||||
struct JSTestRunnerCounts {
|
||||
int tests_failed { 0 };
|
||||
int tests_passed { 0 };
|
||||
int tests_skipped { 0 };
|
||||
int suites_failed { 0 };
|
||||
int suites_passed { 0 };
|
||||
int files_total { 0 };
|
||||
};
|
||||
|
||||
class TestRunnerGlobalObject final : public JS::GlobalObject {
|
||||
JS_OBJECT(TestRunnerGlobalObject, JS::GlobalObject);
|
||||
|
||||
@ -109,7 +100,7 @@ public:
|
||||
|
||||
void run();
|
||||
|
||||
const JSTestRunnerCounts& counts() const { return m_counts; }
|
||||
const Test::Counts& counts() const { return m_counts; }
|
||||
|
||||
bool is_printing_progress() const { return m_print_progress; }
|
||||
|
||||
@ -126,7 +117,7 @@ protected:
|
||||
bool m_print_progress;
|
||||
|
||||
double m_total_elapsed_time_in_ms { 0 };
|
||||
JSTestRunnerCounts m_counts;
|
||||
Test::Counts m_counts;
|
||||
|
||||
RefPtr<JS::Program> m_test_program;
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2020, The SerenityOS developers.
|
||||
* Copyright (c) 2020-2021, The SerenityOS developers.
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -66,15 +66,6 @@ struct JSFileResult {
|
||||
Vector<String> logged_messages {};
|
||||
};
|
||||
|
||||
struct JSTestRunnerCounts {
|
||||
int tests_failed { 0 };
|
||||
int tests_passed { 0 };
|
||||
int tests_skipped { 0 };
|
||||
int suites_failed { 0 };
|
||||
int suites_passed { 0 };
|
||||
int files_total { 0 };
|
||||
};
|
||||
|
||||
Function<void(const URL&)> g_on_page_change;
|
||||
|
||||
class TestRunnerObject final : public JS::Object {
|
||||
@ -138,7 +129,7 @@ private:
|
||||
bool m_print_times;
|
||||
|
||||
double m_total_elapsed_time_in_ms { 0 };
|
||||
JSTestRunnerCounts m_counts;
|
||||
Test::Counts m_counts;
|
||||
|
||||
RefPtr<Web::InProcessWebView> m_page_view;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user