Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
I
ink
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Insights
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Security & Compliance
Security & Compliance
Dependency List
Packages
Packages
List
Container Registry
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Jobs
Commits
Open sidebar
parity
ink
Commits
8e711417
Unverified
Commit
8e711417
authored
Nov 11, 2019
by
Robin Freyler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[lang2/macro] add test for unknown ink! method marker
parent
15d2066c
Pipeline
#56549
failed with stages
in 1 minute and 32 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
0 deletions
+31
-0
lang2/macro/tests/compile_tests.rs
lang2/macro/tests/compile_tests.rs
+1
-0
lang2/macro/tests/ui/fail/20-unknown-method-marker.rs
lang2/macro/tests/ui/fail/20-unknown-method-marker.rs
+25
-0
lang2/macro/tests/ui/fail/20-unknown-method-marker.stderr
lang2/macro/tests/ui/fail/20-unknown-method-marker.stderr
+5
-0
No files found.
lang2/macro/tests/compile_tests.rs
View file @
8e711417
...
...
@@ -43,4 +43,5 @@ fn compile_tests() {
t
.compile_fail
(
"tests/ui/fail/17-conflicting-ink-markers.rs"
);
t
.compile_fail
(
"tests/ui/fail/18-conflicting-ink-markers-2.rs"
);
t
.compile_fail
(
"tests/ui/fail/19-unknown-struct-ink-marker.rs"
);
t
.compile_fail
(
"tests/ui/fail/20-unknown-method-marker.rs"
);
}
lang2/macro/tests/ui/fail/20-unknown-method-marker.rs
0 → 100644
View file @
8e711417
#![feature(proc_macro_hygiene)]
use
ink_lang2
as
ink
;
#[ink::contract(version
=
"0.1.0"
)]
mod
noop
{
#[ink(storage)]
struct
Noop
{}
impl
Noop
{
#[ink(constructor)]
fn
new
(
&
mut
self
)
{}
#[ink(message)]
fn
noop
(
&
self
)
{}
#[ink(unknown_marker)]
fn
has_unknown_marker
(
&
self
)
{}
#[ink(unknown_marker_2)]
fn
has_unknown_marker_too
(
&
mut
self
)
{}
}
}
fn
main
()
{}
lang2/macro/tests/ui/fail/20-unknown-method-marker.stderr
0 → 100644
View file @
8e711417
error: unknown ink! marker
--> $DIR/20-unknown-method-marker.rs:17:14
|
17 | #[ink(unknown_marker)]
| ^^^^^^^^^^^^^^^^
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment