Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0f520c9
commit 31c95e9
Showing
1 changed file
with
11 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# I am not sure how to execute these tests from harness. | ||
use v6; | ||
use Test; | ||
|
||
plan 5; | ||
|
||
ok 1 == eval( '1', :lang<perl5>), 'eval Integer'; | ||
ok 1 == eval( '1', :lang<perl5>), 'eval Num'; | ||
ok 'a' eq eval( '"a"', :lang<perl5>), 'eval String'; | ||
ok 'ok' eq eval( 'sub A::t { $_[1]->[0] . $_[1]->[1] }; bless {}, A', :lang<perl5> ).t( < o k > ), 'eval Array'; | ||
ok 'ok' eq eval( 'sub A::t { $_[1]->{a} }; bless {}, A', :lang<perl5> ).t( { :a<ok> } ), 'eval Hash'; |
31c95e9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Which languages should we be writing tests in? We are going to at least have to check that v6.pm is installed.
31c95e9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps we should have a directory for tests written in Perl 6/v6.pm ? Then it will be easier to conditionally run them, if the requirements are met.