forked from dotnet/fsharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAssemblyTitle_001.fs
More file actions
23 lines (19 loc) · 865 Bytes
/
Copy pathAssemblyTitle_001.fs
File metadata and controls
23 lines (19 loc) · 865 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
// AssemblyAttributes
// See FSHARP1.0:832,1674,1675 and 2290
// Attribute under test: AssemblyTitle
//<Expects status="success"></Expects>
#light
open System
open System.Reflection;
open System.Configuration.Assemblies
let CheckAssemblyAttribute () =
let path_to_myself = Assembly.GetExecutingAssembly().Location
let actualvalue = System.Diagnostics.FileVersionInfo.GetVersionInfo(path_to_myself).FileDescription
let expectedvalue = "I'm a title"
if actualvalue = expectedvalue then
0
else
printfn "FAIL: Expected %A; Actual: %A" expectedvalue actualvalue
1
[<assembly:AssemblyTitleAttribute("I'm a title")>]
do CheckAssemblyAttribute () |> exit