Parallel Letter Frequency
This commit is contained in:
parent
3ca9867a11
commit
af89290bbc
45 changed files with 2862 additions and 0 deletions
28
sqlite/hello-world/hello-world_test.sql
Normal file
28
sqlite/hello-world/hello-world_test.sql
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
-- Setup test table and read in student solution:
|
||||
.read ./test_setup.sql
|
||||
-- Test cases:
|
||||
INSERT INTO
|
||||
tests (name, uuid, expected)
|
||||
VALUES
|
||||
(
|
||||
'Say Hi!',
|
||||
'af9ffe10-dc13-42d8-a742-e7bdafac449d',
|
||||
'Hello, World!'
|
||||
);
|
||||
|
||||
-- Comparison of user input and the tests updates the status for each test:
|
||||
UPDATE tests
|
||||
SET
|
||||
status = 'pass'
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
greeting
|
||||
FROM
|
||||
hello_world
|
||||
) AS actual
|
||||
WHERE
|
||||
actual.greeting = tests.expected;
|
||||
|
||||
-- Write results and debug info:
|
||||
.read ./test_reporter.sql
|
||||
Loading…
Add table
Add a link
Reference in a new issue