Linus Groh
bfbd6df892
test-js: Show progress in taskbar
...
This was a nice feature the old run-tests.sh script had - let's add it
to test-js as well! :^)
2020-07-07 10:40:06 +02:00
Linus Groh
4c845b35ac
Base: Add man page for test-js(1)
2020-07-07 10:39:48 +02:00
Andrew Kaster
02018af0cc
Demos: Print out ELF Auxiliary Vector in LinkDemo
...
This is a test program anyway, so let's double check that the auxv
is done properly here.
2020-07-07 10:38:54 +02:00
Andrew Kaster
f96b827990
Kernel+LibELF: Expose ELF Auxiliary Vector to Userspace
...
The AT_* entries are placed after the environment variables, so that
they can be found by iterating until the end of the envp array, and then
going even further beyond :^)
2020-07-07 10:38:54 +02:00
Linus Groh
8b76a1e548
js: Remove test mode
...
Now that we have a standalone test-js program, the "-t" test mode of the
js REPL is unused and can simply be removed. Required functionality has
been duplicated in test-js (isStrictMode function, loading of testing
utilities).
Also remove outdated information about tests from the js(1) man page.
2020-07-07 00:21:30 +02:00
Andreas Kling
651829c1e6
test-js: Use Core::File::is_directory(path) instead of opening file
2020-07-06 23:46:29 +02:00
Matthew Olsson
695ba071a8
test-js: Remove tests_to_run in favor of a DirIterator
2020-07-06 23:40:35 +02:00
Linus Groh
461d90d042
LibJS: Convert Array tests to new testing framework
2020-07-06 23:40:35 +02:00
Linus Groh
8ebdf685a6
LibJS: Split isNaN tests into multiple sections
2020-07-06 23:40:35 +02:00
Matthew Olsson
1ef573eb30
LibJS: Indent tests with 4 spaces instead of 2
2020-07-06 23:40:35 +02:00
Matthew Olsson
15de2eda2b
LibJS: Convert all remaining non-Array tests to the new system :)
2020-07-06 23:40:35 +02:00
Matthew Olsson
918f4affd5
LibJS: Convert remaining top-level tests to new system
2020-07-06 23:40:35 +02:00
Matthew Olsson
6d58c48c2f
test-js: Use prettier and format all files
2020-07-06 23:40:35 +02:00
Matthew Olsson
e532888242
test-js: Only print files with failed or skipped tests
...
This does not affect output when the "-t" flag is specified -- all files
will still be printed in that case.
2020-07-06 23:40:35 +02:00
Matthew Olsson
a2dbd955f2
test-js: Display messages from console.log in test output
...
This will help greatly with debugging!
2020-07-06 23:40:35 +02:00
Matthew Olsson
474159277f
Base: Add information box emoji
...
ℹ️
2020-07-06 23:40:35 +02:00
Matthew Olsson
38648f1758
test-js: Only parse test-common.js once
2020-07-06 23:40:35 +02:00
Matthew Olsson
a822512443
test-js: Print duration of each test when given '-t' flag
2020-07-06 23:40:35 +02:00
Matthew Olsson
82fa65135a
test-js: Allow skipping tests with "test.skip(name, callback)"
...
Skipped tests count as a "pass" rather than a "fail" (i.e. a test suite
with a skipped test will pass), however it does display a message when
the test is printing.
This is intended for tests which _should_ work, but currently do not.
This should be preferred over "// FIXME" notes if possible.
2020-07-06 23:40:35 +02:00
Matthew Olsson
cf537311e4
test-js: Remove run-tests.sh
...
The shell script is no longer necessary -- simply run "test-js" from
inside Serenity, or $SERENITY_ROOT/Build/Meta/Lagom/test-js from the
host.
2020-07-06 23:40:35 +02:00
Matthew Olsson
26acc8ba88
LibJS/test-js: Clean up test-js code
...
This commit also exposes JSONObject's implementation of stringify to the
public, so that it can be used by test-js without having to go through
the interpreter's environment.
2020-07-06 23:40:35 +02:00
Matthew Olsson
4c6fd49169
LibJS: Fix String.raw.length
2020-07-06 23:40:35 +02:00
Matthew Olsson
3f97d75778
LibJS: Convert most builtin tests to new system
2020-07-06 23:40:35 +02:00
Linus Groh
46581773c1
LibJS: Convert Reflect object tests to new testing framework
2020-07-06 23:40:35 +02:00
Matthew Olsson
fc08222f46
LibJS: Add more test matchers
2020-07-06 23:40:35 +02:00
Matthew Olsson
5e971c91e3
LibJS: Hide some debug output behind flags
...
This hides some Object.cpp output, as well as removing the "debugger"
debug output.
2020-07-06 23:40:35 +02:00
Matthew Olsson
449a1cf3a2
LibJS: Convert Proxy tests
2020-07-06 23:40:35 +02:00
Matthew Olsson
b86faeaeef
LibJS: Add test-common.js tests, remove unused matchers
...
Now that test-common.js is quite a bit more complicated, we need tests
for test-common to make sure all of the matchers behave correctly
2020-07-06 23:40:35 +02:00
Matthew Olsson
eea6041302
LibJS: Convert some top-level tests to the new system
...
First test conversions! These look really good :)
2020-07-06 23:40:35 +02:00
Matthew Olsson
4b8a3e6d78
LibJS: Refactor run-tests.sh to use the new test-js program
2020-07-06 23:40:35 +02:00
Matthew Olsson
b9cf7a833f
LibJS/test-js: Create test-js program, prepare for test suite refactor
...
This moves most of the work from run-tests.sh to test-js.cpp. This way,
we have a lot more control over how the test suite runs, as well as how
it outputs. This should result in some cool functionality!
This commit also refactors test-common.js to mimic the jest library.
This should allow tests to be much more expressive :)
2020-07-06 23:40:35 +02:00
Andreas Kling
c43afe71b7
LibWeb: Make WebContentView show the hover hand over links :^)
2020-07-06 23:32:12 +02:00
Andreas Kling
41066b009f
LibCore: Don't fire Socket::on_ready_to_read if !can_read()
...
This is a bit of a pickle and I'm unsure what's the best behavior here.
Since notifiers fire asynchronously via the event loop, we may end up
firing a notifier for a socket fd, but then reading/writing that socket
fd before ending up in the notifier callback.
In that situation, the socket is no longer in the same state as it was
when the event loop generated the notifier event.
This patch stops Socket from firing one hook in this situation but this
probably needs a global rethink.
With this change, Browser starts reliably in multi-process mode. :^)
2020-07-06 23:17:10 +02:00
Andreas Kling
e5933ec739
LibCore: Only deliver Read/Write events to listening notifiers
...
If a notifier has disabled read/write notifications via its event mask,
we should not spam it with events, even if they have a hook callback.
2020-07-06 23:17:10 +02:00
Nico Weber
f27e5ac68d
LibLine: Support Ctrl-b/f and Ctrl-d
...
And make the existing cltr-h handler easier to see.
2020-07-06 22:41:35 +02:00
Nico Weber
72f8b3d185
LibLine: Extract lambdas for cursor-left, cursor-right, delete
...
Also move the existing backspace lambda out of the loop.
The do_delete() extraction fixes a minor bug where
InputState::ExpectTerminator wasn't entered if delete was pressed at the
very end of a line. Now that this is fixed, there's no more
"LibLine: Unhandled final: 7e (~)" when hitting delete at the end of the
line.
2020-07-06 22:41:35 +02:00
Nico Weber
8c82138b22
LibLine: Put ctrl-key handlers in alphabetical order
2020-07-06 22:41:35 +02:00
Nico Weber
4726966ad7
LibLine: Replace some magic numbers with a magic function
2020-07-06 22:41:35 +02:00
AnotherTest
a163ee8b3b
TextEditor: Use ArgsParser and allow the user to specify preview mode
...
This makes looking at HTML files that somehow fail a little less
painful by allowing the user to actually _see_ the html.
2020-07-06 22:40:38 +02:00
AnotherTest
5cdb0ef2e5
Shell: Keep the TTY on the same pgroup to get tty signals
...
This allows the shell to be notified about SIGWINCH even when a child
process is running in the foreground.
2020-07-06 22:39:32 +02:00
AnotherTest
5fedf90bf9
LibLine: Avoid refreshing the display when resizing
...
This allows was_resized() to be called while the editor is not active
(i.e. get_line() is not in frame).
2020-07-06 22:39:32 +02:00
Tom
06d50f64b0
Kernel: Aggregate TLB flush requests for Regions for SMP
...
Rather than sending one TLB flush request for each page,
aggregate them so that we're not spamming the other
processors with FlushTLB IPIs.
2020-07-06 22:39:06 +02:00
Andreas Kling
56126d7a45
LibWeb: Don't show unnecessary scrollbars in WebContentView
...
This behaves a little weird right now, and will probably require more
coordination between the widget and the WebContent process.
2020-07-06 22:02:38 +02:00
Andreas Kling
9169c8ca94
LibWeb: Make the WebContentView::on_load_start hook actually work :^)
2020-07-06 21:58:16 +02:00
Andreas Kling
a94ef9e021
Browser: Add a way to start Browser in multi-process mode :^)
...
You can enable the new multi-process mode by using "Browser -m".
2020-07-06 21:50:45 +02:00
Andreas Kling
d8be535579
Browser+LibWeb: Pave the way for using WebContentView in Browser
...
This commit sets everything up, but we still always instantiate a plain
Web::PageView in Browser::Tab..
2020-07-06 21:46:37 +02:00
Andreas Kling
49b9a0a665
LibWeb: Add a shared WebViewHooks base class for both web view widgets
...
This will make it easier for Browser to share code between both views.
2020-07-06 21:19:03 +02:00
Andreas Kling
7a7e39c7af
LibWeb: Move WebContentView from Demos/WebView into LibWeb
2020-07-06 20:36:34 +02:00
Andreas Kling
32243e1df2
WebContent: Plumb link clicks to the WebContentView :^)
...
You can now react to links being clicked via the on_link_click hook.
2020-07-06 20:02:30 +02:00
Andreas Kling
fd65a24834
LibWeb: Make the link context menu hook include the destination URL
2020-07-06 20:00:56 +02:00