Description:
Fixed truncate
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r370:9b23889aa864 - - 1 file changed: 1 inserted, 1 deleted
@@ -1,40 +1,40 | |||
|
1 | 1 | %h1= "Test Request: #{@test_request.id}" |
|
2 | 2 | |
|
3 | 3 | %p |
|
4 | 4 | User: |
|
5 | 5 | = "#{@test_request.user.login}" |
|
6 | 6 | %br/ |
|
7 | 7 | Problem: |
|
8 | 8 | - if @test_request.problem!=nil |
|
9 | 9 | = "#{@test_request.problem.full_name}" |
|
10 | 10 | - else |
|
11 | 11 | = "(n/a)" |
|
12 | 12 | %br/ |
|
13 | 13 | = "Submission: #{@test_request.submission.number}" |
|
14 | 14 | = link_to '[view submission]', :action => 'submission', :id => @test_request.submission.id |
|
15 | 15 | %br/ |
|
16 | 16 | = "Test submitted at: #{format_short_time(@test_request.submitted_at)}" |
|
17 | 17 | %br/ |
|
18 | 18 | = "Execution time: #{@test_request.running_time} s." |
|
19 | 19 | %br/ |
|
20 | 20 | = "Memory usage: #{@test_request.memory_usage}kb" |
|
21 | 21 | %br/ |
|
22 | 22 | %b= @test_request.exit_status |
|
23 | 23 | %br/ |
|
24 | 24 | |
|
25 | 25 | - if @test_request.compiler_message!=nil and @test_request.compiler_message!='' |
|
26 | 26 | %b Compiler Message |
|
27 | 27 | %div{:style => "border: 1px solid black; background: lightgrey"} |
|
28 | - = simple_format(truncate((@test_request.compiler_message or ''),200)) | |
|
28 | + = simple_format(truncate((@test_request.compiler_message or ''), :length => 200)) | |
|
29 | 29 | |
|
30 | 30 | %b Input (first 2kb) |
|
31 | 31 | %div{:style => "border: 1px solid black; background: lightgrey"} |
|
32 | 32 | - if @test_request.input_file_name!=nil |
|
33 | 33 | = simple_format(read_textfile(@test_request.input_file_name,2048)) |
|
34 | 34 | |
|
35 | 35 | %b Output (first 2kb) |
|
36 | 36 | %div{:style => "border: 1px solid black; background: lightgrey"} |
|
37 | 37 | - if @test_request.output_file_name!=nil |
|
38 | 38 | = simple_format(read_textfile(@test_request.output_file_name,2048)) |
|
39 | 39 | - else |
|
40 | 40 | (no output) |
You need to be logged in to leave comments.
Login now