move compiler tests from compiler/ to v/

pull/4134/head
Alexander Medvednikov 2020-03-27 18:01:46 +01:00
parent 95e67c9502
commit eed7c91e87
132 changed files with 18 additions and 18 deletions

View File

@ -20,8 +20,8 @@ const (
'./vlib/arrays/arrays.v', './vlib/arrays/arrays.v',
'./vlib/arrays/arrays_test.v', './vlib/arrays/arrays_test.v',
'./vlib/builtin/js/hashmap.v', './vlib/builtin/js/hashmap.v',
'./vlib/compiler/tests/fn_variadic_test.v', './vlib/v/tests/fn_variadic_test.v',
'./vlib/compiler/tests/generic_test.v', './vlib/v/tests/generic_test.v',
'./vlib/crypto/aes/aes.v', './vlib/crypto/aes/aes.v',
'./vlib/crypto/aes/aes_cbc.v', './vlib/crypto/aes/aes_cbc.v',
'./vlib/crypto/aes/block_generic.v', './vlib/crypto/aes/block_generic.v',

View File

@ -59,4 +59,4 @@ fn greet_pre_func(cmd cli.Command) {
fn greet_post_func(cmd cli.Command) { fn greet_post_func(cmd cli.Command) {
println('This is a function running after the main function') println('This is a function running after the main function')
} }

View File

@ -321,4 +321,4 @@ pub fn aprox_cos(a f64) f64 {
a7 := 4.7196604604366623e-4 a7 := 4.7196604604366623e-4
a8 := -1.8776444013090451e-5 a8 := -1.8776444013090451e-5
return a0 + a * (a1 + a * (a2 + a * (a3 + a * (a4 + a * (a5 + a * (a6 + a * (a7 + a * a8))))))) return a0 + a * (a1 + a * (a2 + a * (a3 + a * (a4 + a * (a5 + a * (a6 + a * (a7 + a * a8)))))))
} }

View File

@ -256,4 +256,4 @@ pub fn activate_context(ctx_id C.sg_context) {
[inline] [inline]
pub fn discard_context(ctx_id C.sg_context) { pub fn discard_context(ctx_id C.sg_context) {
C.sg_discard_context(ctx_id) C.sg_discard_context(ctx_id)
} }

View File

@ -64,4 +64,4 @@ fn C.sg_query_pass_defaults(desc &C.sg_pass) C.sg_pass_desc
/* rendering contexts (optional) */ /* rendering contexts (optional) */
fn C.sg_setup_context() C.sg_context fn C.sg_setup_context() C.sg_context
fn C.sg_activate_context(ctx_id C.sg_context) fn C.sg_activate_context(ctx_id C.sg_context)
fn C.sg_discard_context(ctx_id C.sg_context) fn C.sg_discard_context(ctx_id C.sg_context)

View File

@ -68,4 +68,4 @@ fn C.sapp_d3d11_get_depth_stencil_view() voidptr
/* Win32: get the HWND window handle */ /* Win32: get the HWND window handle */
fn C.sapp_win32_get_hwnd() voidptr fn C.sapp_win32_get_hwnd() voidptr
/* Android: get native activity handle */ /* Android: get native activity handle */
fn C.sapp_android_get_native_activity() voidptr fn C.sapp_android_get_native_activity() voidptr

View File

@ -10,4 +10,4 @@ fn test_levenshtein_distance() {
assert strings.levenshtein_distance('hugs', 'shrugs') == 2 assert strings.levenshtein_distance('hugs', 'shrugs') == 2
assert strings.levenshtein_distance('broom', 'shroom') == 2 assert strings.levenshtein_distance('broom', 'shroom') == 2
assert strings.levenshtein_distance('flomax', 'volmax') == 3 assert strings.levenshtein_distance('flomax', 'volmax') == 3
} }

View File

@ -30,4 +30,4 @@ fn test_fn_attribute() {
[testing] [testing]
pub fn test_pub_fn_attribute() { pub fn test_pub_fn_attribute() {
assert true assert true
} }

View File

@ -7,7 +7,7 @@ fn test_all() {
} }
vexe := os.getenv('VEXE') vexe := os.getenv('VEXE')
vroot := os.dir(vexe) vroot := os.dir(vexe)
dir := os.join_path(vroot,'vlib/v/tests') dir := os.join_path(vroot,'vlib/v/tests/inout')
files := os.ls(dir) or { files := os.ls(dir) or {
panic(err) panic(err)
} }

View File

@ -1,5 +1,5 @@
import compiler.tests.local import v.tests.local
fn test_local_module_is_callable() { fn test_local_module_is_callable() {
assert local.local_fn() assert local.local_fn()

View File

@ -161,4 +161,4 @@ fn test_multi_return_opt() {
assert err == 'oops' assert err == 'oops'
return return
} }
} }

View File

@ -1,7 +1,7 @@
// Build and run files in ./prod/ folder, comparing their output to *.expected.txt files. // Build and run files in ./prod/ folder, comparing their output to *.expected.txt files.
// (Similar to REPL tests, but in -prod mode.) // (Similar to REPL tests, but in -prod mode.)
// import os // import os
import compiler.tests.repl.runner import v.tests.repl.runner
import benchmark import benchmark
fn test_all_v_prod_files() { fn test_all_v_prod_files() {

View File

@ -1,3 +1,3 @@
import compiler.tests.modules.acommentedmodule import v.tests.modules.acommentedmodule
===output=== ===output===
vlib/compiler/tests/modules/acommentedmodule/commentedfile.v:7:1: bad module definition: vlib/compiler/tests/modules/acommentedmodule/commentedfile.v imports module "compiler.tests.modules.acommentedmodule" but vlib/compiler/tests/modules/acommentedmodule/commentedfile.v is defined as module `main` vlib/compiler/tests/modules/acommentedmodule/commentedfile.v:7:1: bad module definition: vlib/compiler/tests/modules/acommentedmodule/commentedfile.v imports module "compiler.tests.modules.acommentedmodule" but vlib/compiler/tests/modules/acommentedmodule/commentedfile.v is defined as module `main`

Some files were not shown because too many files have changed in this diff Show More