text:
namespace Email.Tests

open Expecto

        // https://tools.ietf.org/html/rfc2822
        // https://tools.ietf.org/html/rfc2822#section-3.2.4
        // https://tools.ietf.org/html/rfc2822#section-3.4.1
        // ( see also RFC 5322 )
        //
        // http://www.ex-parrot.com/pdw/Mail-RFC822-Address.html
        //
        // http://emailregex.com/
        //
        // http://stackoverflow.com/questions/297420/list-of-email-addresses-that-can-be-used-to-test-a-javascript-validation-script

/// RFC822 tests from http://code.iamcal.com/php/rfc822/tests/
module RFC822 =

    [<Literal>]
    let Valid = true

    [<Literal>]
    let Invalid = false

    let test1 (f : string -> bool) =
        testCase "test1" <| fun () ->
            Expect.isTrue ((f @"first.last@iana.org") = Valid) "Expcect Valid"

    let test2 (f : string -> bool) =
        testCase "test2" <| fun () ->
            Expect.isTrue ((f @"1234567890123456789012345678901234567890123456789012345678901234@iana.org") = Valid) "Expcect Valid"

    let test3 (f : string -> bool) =
        testCase "test3" <| fun () ->
            Expect.isTrue ((f @"first.last@sub.do,com") = Invalid) "Expcect Invalid"

    let test4 (f : string -> bool) =
    //"first\"last"@iana.org
        testCase "test4" <| fun () ->
            Expect.isTrue ((f "\"first\\\"last\"@iana.org") = Valid) "Expcect Valid"

    let test5 (f : string -> bool) =
        testCase "test5" <| fun () ->
            Expect.isTrue ((f @"first\@last@iana.org") = Invalid) "Expcect Invalid"

    let test6 (f : string -> bool) =
    //"first@last"@iana.org
        testCase "test6" <| fun () ->
            Expect.isTrue ((f "\"first@last\"@iana.org") = Valid) "Expcect Valid"

    let test7 (f : string -> bool) =
    //"first\\last"@iana.org
        testCase "test7" <| fun () ->
            Expect.isTrue ((f "\"first\\\\last\"@iana.org") = Valid) "Expcect Valid"

    let test8 (f : string -> bool) =
        testCase "test8" <| fun () ->
            Expect.isTrue ((f @"x@x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x2")
                = Valid) "Expcect Valid"

    let test9 (f : string -> bool) =
        testCase "test9" <| fun () ->
            Expect.isTrue ((f @"1234567890123456789012345678901234567890123456789012345678@12345678901234567890123456789012345678901234567890123456789.12345678901234567890123456789012345678901234567890123456789.123456789012345678901234567890123456789012345678901234567890123.iana.org")
                = Valid) "Expcect Valid"

    let test10 (f : string -> bool) =
        testCase "test10" <| fun () ->
            Expect.isTrue ((f @"first.last@[12.34.56.78]") = Valid) "Expcect Valid"

    let test11 (f : string -> bool) =
        testCase "test11" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::12.34.56.78]") = Valid) "Expcect Valid"

    let test12 (f : string -> bool) =
        testCase "test12" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333::4444:12.34.56.78]") = Valid) "Expcect Valid"

    let test13 (f : string -> bool) =
        testCase "test13" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:12.34.56.78]") = Valid) "Expcect Valid"

    let test14 (f : string -> bool) =
        testCase "test14" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::1111:2222:3333:4444:5555:6666]") = Valid) "Expcect Valid"

    let test15 (f : string -> bool) =
        testCase "test15" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333::4444:5555:6666]") = Valid) "Expcect Valid"

    let test16 (f : string -> bool) =
        testCase "test16" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666::]") = Valid) "Expcect Valid"

    let test17 (f : string -> bool) =
        testCase "test17" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:7777:8888]") = Valid) "Expcect Valid"

    let test18 (f : string -> bool) =
        testCase "test18" <| fun () ->
            Expect.isTrue ((f @"first.last@x23456789012345678901234567890123456789012345678901234567890123.iana.org")
                = Valid) "Expcect Valid"

    let test19 (f : string -> bool) =
        testCase "test19" <| fun () ->
            Expect.isTrue ((f @"first.last@3com.com") = Valid) "Expcect Valid"

    let test20 (f : string -> bool) =
        testCase "test20" <| fun () ->
            Expect.isTrue ((f @"first.last@123.iana.org") = Valid) "Expcect Valid"

    let test21 (f : string -> bool) =
        testCase "test21" <| fun () ->
            Expect.isTrue ((f @"123456789012345678901234567890123456789012345678901234567890@12345678901234567890123456789012345678901234567890123456789.12345678901234567890123456789012345678901234567890123456789.12345678901234567890123456789012345678901234567890123456789.12345.iana.org")
                = Invalid) "Expcect Invalid"

    let test22 (f : string -> bool) =
        testCase "test22" <| fun () ->
            Expect.isTrue ((f @"first.last") = Invalid) "Expcect Invalid"

    let test23 (f : string -> bool) =
        testCase "test23" <| fun () ->
            Expect.isTrue ((f @"12345678901234567890123456789012345678901234567890123456789012345@iana.org") = Invalid) "Expcect Invalid"

    let test24 (f : string -> bool) =
        testCase "test24" <| fun () ->
            Expect.isTrue ((f @".first.last@iana.org") = Invalid) "Expcect Invalid"

    let test25 (f : string -> bool) =
        testCase "test25" <| fun () ->
            Expect.isTrue ((f @"first.last.@iana.org") = Invalid) "Expcect Invalid"

    let test26 (f : string -> bool) =
        testCase "test26" <| fun () ->
            Expect.isTrue ((f @"first..last@iana.org") = Invalid) "Expcect Invalid"

    let test27 (f : string -> bool) =
    //"first"last"@iana.org
        testCase "test27" <| fun () ->
            Expect.isTrue ((f "\"first\"last\"@iana.org") = Invalid) "Expcect Invalid"

    let test28 (f : string -> bool) =
    //"first\last"@iana.org
        testCase "test28" <| fun () ->
            Expect.isTrue ((f "\"first\\last\"@iana.org") = Valid) "Expcect Valid"

    let test29 (f : string -> bool) =
    //"""@iana.org
        testCase "test29" <| fun () ->
            Expect.isTrue ((f "\"\"\"@iana.org") = Invalid) "Expcect Invalid"

    let test30 (f : string -> bool) =
    //"\"@iana.org
        testCase "test30" <| fun () ->
            Expect.isTrue ((f "\"\\\"@iana.org") = Invalid) "Expcect Invalid"

    let test31 (f : string -> bool) =
    //""@iana.org
        testCase "test31" <| fun () ->
            Expect.isTrue ((f "\"\"@iana.org") = Invalid) "Expcect Invalid"

    let test32 (f : string -> bool) =
        testCase "test32" <| fun () ->
            Expect.isTrue ((f @"first\\@last@iana.org") = Invalid) "Expcect Invalid"

    let test33 (f : string -> bool) =
        testCase "test33" <| fun () ->
            Expect.isTrue ((f @"first.last@") = Invalid) "Expcect Invalid"

    let test34 (f : string -> bool) =
        testCase "test34" <| fun () ->
            Expect.isTrue ((f @"x@x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456789.x23456") = Invalid) "Expcect Invalid"

    let test35 (f : string -> bool) =
        testCase "test35" <| fun () ->
            Expect.isTrue ((f @"first.last@[.12.34.56.78]") = Invalid) "Expcect Invalid"

    let test36 (f : string -> bool) =
        testCase "test36" <| fun () ->
            Expect.isTrue ((f @"first.last@[12.34.56.789]") = Invalid) "Expcect Invalid"

    let test37 (f : string -> bool) =
        testCase "test37" <| fun () ->
            Expect.isTrue ((f @"first.last@[::12.34.56.78]") = Invalid) "Expcect Invalid"

    let test38 (f : string -> bool) =
        testCase "test37" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv5:::12.34.56.78]") = Invalid) "Expcect Invalid"

    let test39 (f : string -> bool) =
        testCase "test38" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333::4444:5555:12.34.56.78]") = Valid) "Expcect Valid"

    let test40 (f : string -> bool) =
        testCase "test40" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:12.34.56.78]") = Invalid) "Expcect Invalid"

    let test41 (f : string -> bool) =
        testCase "test41" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:7777:12.34.56.78]") = Invalid) "Expcect Invalid"

    let test42 (f : string -> bool) =
        testCase "test42" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:7777]") = Invalid) "Expcect Invalid"

    let test43 (f : string -> bool) =
        testCase "test43" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:7777:8888:9999]") = Invalid) "Expcect Invalid"

    let test44 (f : string -> bool) =
        testCase "test44" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222::3333::4444:5555:6666]") = Invalid) "Expcect Invalid"

    let test45 (f : string -> bool) =
        testCase "test45" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333::4444:5555:6666:7777]") = Valid) "Expcect Valid"

    let test46 (f : string -> bool) =
        testCase "test46" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:333x::4444:5555]") = Invalid) "Expcect Invalid"

    let test47 (f : string -> bool) =
        testCase "test47" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:33333::4444:5555]") = Invalid) "Expcect Invalid"

    let test48 (f : string -> bool) =
        testCase "test48" <| fun () ->
            Expect.isTrue ((f @"first.last@example.123") = Valid) "Expcect Valid"

    let test49 (f : string -> bool) =
        testCase "test49" <| fun () ->
            Expect.isTrue ((f @"first.last@com") = Valid) "Expcect Valid"

    let test50 (f : string -> bool) =
        testCase "test50" <| fun () ->
            Expect.isTrue ((f @"first.last@-xample.com") = Invalid) "Expcect Invalid"

    let test51 (f : string -> bool) =
        testCase "test51" <| fun () ->
            Expect.isTrue ((f @"first.last@exampl-.com") = Invalid) "Expcect Invalid"

    let test52 (f : string -> bool) =
        testCase "test52" <| fun () ->
            Expect.isTrue ((f @"first.last@x234567890123456789012345678901234567890123456789012345678901234.iana.org")
                = Invalid) "Expcect Invalid"

    let test53 (f : string -> bool) =
    //"Abc\@def"@iana.org
        testCase "test53" <| fun () ->
            Expect.isTrue ((f "\"Abc\\@def\"@iana.org") = Valid) "Expcect Valid"

    let test54 (f : string -> bool) =
    //"Fred\ Bloggs"@iana.org
        testCase "test54" <| fun () ->
            Expect.isTrue ((f "\"Fred\\ Bloggs\"@iana.org") = Valid) "Expcect Valid"

    let test55 (f : string -> bool) =
    //"Joe.\\Blow"@iana.org
        testCase "test55" <| fun () ->
            Expect.isTrue ((f "\"Joe.\\\\Blow\"@iana.org") = Valid) "Expcect Valid"

    let test56 (f : string -> bool) =
    //"Abc@def"@iana.org
        testCase "test56" <| fun () ->
            Expect.isTrue ((f "\"Abc@def\"@iana.org") = Valid) "Expcect Valid"

    let test57 (f : string -> bool) =
    //"Fred Bloggs"@iana.org
        testCase "test57" <| fun () ->
            Expect.isTrue ((f "\"Fred Bloggs\"@iana.org") = Valid) "Expcect Valid"

    let test58 (f : string -> bool) =
        testCase "test58" <| fun () ->
            Expect.isTrue ((f @"user+mailbox@iana.org") = Valid) "Expcect Valid"

    let test59 (f : string -> bool) =
        testCase "test59" <| fun () ->
            Expect.isTrue ((f @"customer/department=shipping@iana.org") = Valid) "Expcect Valid"

    let test60 (f : string -> bool) =
        testCase "test60" <| fun () ->
            Expect.isTrue ((f @"$A12345@iana.org") = Valid) "Expcect Valid"

    let test61 (f : string -> bool) =
        testCase "test61" <| fun () ->
            Expect.isTrue ((f @"!def!xyz%abc@iana.org") = Valid) "Expcect Valid"

    let test62 (f : string -> bool) =
        testCase "test62" <| fun () ->
            Expect.isTrue ((f @"_somename@iana.org") = Valid) "Expcect Valid"

    let test63 (f : string -> bool) =
        testCase "test63" <| fun () ->
            Expect.isTrue ((f @"dclo@us.ibm.com") = Valid) "Expcect Valid"

    let test64 (f : string -> bool) =
        testCase "test64" <| fun () ->
            Expect.isTrue ((f @"abc\@def@iana.org") = Invalid) "Expcect Invalid"

    let test65 (f : string -> bool) =
        testCase "test65" <| fun () ->
            Expect.isTrue ((f @"abc\\@iana.org") = Invalid) "Expcect Invalid"

    let test66 (f : string -> bool) =
        testCase "test66" <| fun () ->
            Expect.isTrue ((f @"peter.piper@iana.org") = Valid) "Expcect Valid"

    let test67 (f : string -> bool) =
    //Doug\ \"Ace\"\ Lovell@iana.org
        testCase "test67" <| fun () ->
            Expect.isTrue ((f "Doug\\ \\\"Ace\\\"\\ Lovell@iana.org") = Invalid) "Expcect Invalid"

    let test68 (f : string -> bool) =
    //"Doug \"Ace\" L."@iana.org
        testCase "test68" <| fun () ->
            Expect.isTrue ((f "\"Doug \\\"Ace\\\" L.\"@iana.org") = Valid) "Expcect Valid"

    let test69 (f : string -> bool) =
        testCase "test69" <| fun () ->
            Expect.isTrue ((f @"abc@def@iana.org") = Invalid) "Expcect Invalid"

    let test70 (f : string -> bool) =
        testCase "test70" <| fun () ->
            Expect.isTrue ((f @"abc\\@def@iana.org") = Invalid) "Expcect Invalid"

    let test71 (f : string -> bool) =
        testCase "test71" <| fun () ->
            Expect.isTrue ((f @"abc\@iana.org") = Invalid) "Expcect Invalid"

    let test72 (f : string -> bool) =
        testCase "test72" <| fun () ->
            Expect.isTrue ((f @"@iana.org") = Invalid) "Expcect Invalid"

    let test73 (f : string -> bool) =
        testCase "test73" <| fun () ->
            Expect.isTrue ((f @"doug@") = Invalid) "Expcect Invalid"

    let test74 (f : string -> bool) =
    //"qu@iana.org
        testCase "test74" <| fun () ->
            Expect.isTrue ((f "\"qu@iana.org") = Invalid) "Expcect Invalid"

    let test75 (f : string -> bool) =
    //ote"@iana.org
        testCase "test75" <| fun () ->
            Expect.isTrue ((f "ote\"@iana.org") = Invalid) "Expcect Invalid"

    let test76 (f : string -> bool) =
        testCase "test76" <| fun () ->
            Expect.isTrue ((f @".dot@iana.org") = Invalid) "Expcect Invalid"

    let test77 (f : string -> bool) =
        testCase "test77" <| fun () ->
            Expect.isTrue ((f @"dot.@iana.org") = Invalid) "Expcect Invalid"

    let test78 (f : string -> bool) =
        testCase "test78" <| fun () ->
            Expect.isTrue ((f @"two..dot@iana.org") = Invalid) "Expcect Invalid"

    let test79 (f : string -> bool) =
    //"Doug "Ace" L."@iana.org
        testCase "test79" <| fun () ->
            Expect.isTrue ((f "\"Doug \"Ace\" L.\"@iana.org") = Invalid) "Expcect Invalid"

    let test80 (f : string -> bool) =
    //Doug\ \"Ace\"\ L\.@iana.org
        testCase "test80" <| fun () ->
            Expect.isTrue ((f "Doug\\ \\\"Ace\\\"\\ L\\.@iana.org") = Invalid) "Expcect Invalid"

    let test81 (f : string -> bool) =
        testCase "test81" <| fun () ->
            Expect.isTrue ((f @"hello world@iana.org") = Invalid) "Expcect Invalid"

    let test82 (f : string -> bool) =
        testCase "test82" <| fun () ->
            Expect.isTrue ((f @"gatsby@f.sc.ot.t.f.i.tzg.era.l.d.") = Invalid) "Expcect Invalid"

    let test83 (f : string -> bool) =
        testCase "test83" <| fun () ->
            Expect.isTrue ((f @"test@iana.org") = Valid) "Expcect Valid"

    let test84 (f : string -> bool) =
        testCase "test84" <| fun () ->
            Expect.isTrue ((f @"TEST@iana.org") = Valid) "Expcect Valid"

    let test85 (f : string -> bool) =
        testCase "test85" <| fun () ->
            Expect.isTrue ((f @"1234567890@iana.org") = Valid) "Expcect Valid"

    let test86 (f : string -> bool) =
        testCase "test86" <| fun () ->
            Expect.isTrue ((f @"test+test@iana.org") = Valid) "Expcect Valid"

    let test87 (f : string -> bool) =
        testCase "test87" <| fun () ->
            Expect.isTrue ((f @"test-test@iana.org") = Valid) "Expcect Valid"

    let test88 (f : string -> bool) =
        testCase "test88" <| fun () ->
            Expect.isTrue ((f @"t*est@iana.org") = Valid) "Expcect Valid"

    let test89 (f : string -> bool) =
        testCase "test89" <| fun () ->
            Expect.isTrue ((f @"+1~1+@iana.org") = Valid) "Expcect Valid"

    let test90 (f : string -> bool) =
        testCase "test90" <| fun () ->
            Expect.isTrue ((f @"{_test_}@iana.org") = Valid) "Expcect Valid"

    let test91 (f : string -> bool) =
    //"[[ test ]]"@iana.org
        testCase "test91" <| fun () ->
            Expect.isTrue ((f "\"[[ test ]]\"@iana.org") = Valid) "Expcect Valid"

    let test92 (f : string -> bool) =
        testCase "test92" <| fun () ->
            Expect.isTrue ((f @"test.test@iana.org") = Valid) "Expcect Valid"

    let test93 (f : string -> bool) =
    //"test.test"@iana.org
        testCase "test93" <| fun () ->
            Expect.isTrue ((f "\"test.test\"@iana.org") = Valid) "Expcect Valid"

    let test94 (f : string -> bool) =
    //test."test"@iana.org
        testCase "test94" <| fun () ->
            Expect.isTrue ((f "test.\"test\"@iana.org") = Valid) "Expcect Valid"

    let test95 (f : string -> bool) =
    //"test@test"@iana.org
        testCase "test95" <| fun () ->
            Expect.isTrue ((f "\"test@test\"@iana.org") = Valid) "Expcect Valid"

    let test96 (f : string -> bool) =
        testCase "test96" <| fun () ->
            Expect.isTrue ((f @"test@123.123.123.x123") = Valid) "Expcect Valid"

    let test97 (f : string -> bool) =
        testCase "test97" <| fun () ->
            Expect.isTrue ((f @"test@123.123.123.123") = Valid) "Expcect Valid"

    let test98(f : string -> bool) =
        testCase "test98" <| fun () ->
            Expect.isTrue ((f @"test@[123.123.123.123]") = Valid) "Expcect Valid"

    let test99(f : string -> bool) =
        testCase "test99" <| fun () ->
            Expect.isTrue ((f @"test@example.iana.org") = Valid) "Expcect Valid"

    let test100 (f : string -> bool) =
        testCase "test100" <| fun () ->
            Expect.isTrue ((f @"test@example.example.iana.org") = Valid) "Expcect Valid"

    let test101 (f : string -> bool) =
        testCase "test101" <| fun () ->
            Expect.isTrue ((f @"test.iana.org") = Invalid) "Expcect Invalid"

    let test102 (f : string -> bool) =
        testCase "test102" <| fun () ->
            Expect.isTrue ((f @"test.@iana.org") = Invalid) "Expcect Invalid"

    let test103 (f : string -> bool) =
        testCase "test103" <| fun () ->
            Expect.isTrue ((f @"test..test@iana.org") = Invalid) "Expcect Invalid"

    let test104 (f : string -> bool) =
        testCase "test104" <| fun () ->
            Expect.isTrue ((f @".test@iana.org") = Invalid) "Expcect Invalid"

    let test105 (f : string -> bool) =
        testCase "test105" <| fun () ->
            Expect.isTrue ((f @"test@test@iana.org") = Invalid) "Expcect Invalid"

    let test106 (f : string -> bool) =
        testCase "test106" <| fun () ->
            Expect.isTrue ((f @"test@@iana.org") = Invalid) "Expcect Invalid"

    let test107 (f : string -> bool) =
        testCase "test107" <| fun () ->
            Expect.isTrue ((f @"-- test --@iana.org") = Invalid) "Expcect Invalid"

    let test108 (f : string -> bool) =
        testCase "test108" <| fun () ->
            Expect.isTrue ((f @"[test]@iana.org") = Invalid) "Expcect Invalid"

    let test109 (f : string -> bool) =
    //"test\test"@iana.org
        testCase "test109" <| fun () ->
            Expect.isTrue ((f "\"test\\test\"@iana.org") = Valid) "Expcect Valid"

    let test110 (f : string -> bool) =
    //"test"test"@iana.org
        testCase "test110" <| fun () ->
            Expect.isTrue ((f "\"test\"test\"@iana.org") = Invalid) "Expcect Invalid"

    let test111 (f : string -> bool) =
        testCase "test111" <| fun () ->
            Expect.isTrue ((f @"()[]\;:,><@iana.org") = Invalid) "Expcect Invalid"

    let test112 (f : string -> bool) =
        testCase "test112" <| fun () ->
            Expect.isTrue ((f @"test@.") = Invalid) "Expcect Invalid"

    let test113 (f : string -> bool) =
        testCase "test113" <| fun () ->
            Expect.isTrue ((f @"test@example.") = Invalid) "Expcect Invalid"

    let test114 (f : string -> bool) =
        testCase "test114" <| fun () ->
            Expect.isTrue ((f @"test@.org") = Invalid) "Expcect Invalid"

    let test115 (f : string -> bool) =
        testCase "test115" <| fun () ->
            Expect.isTrue ((f @"test@123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012.com")
                = Invalid) "Expcect Invalid"

    let test116 (f : string -> bool) =
        testCase "test116" <| fun () ->
            Expect.isTrue ((f @"test@example") = Valid) "Expcect Valid"

    let test117 (f : string -> bool) =
        testCase "test117" <| fun () ->
            Expect.isTrue ((f @"test@[123.123.123.123") = Invalid) "Expcect Invalid"

    let test118(f : string -> bool) =
        testCase "test118" <| fun () ->
            Expect.isTrue ((f @"test@123.123.123.123]") = Invalid) "Expcect Invalid"

    let test119 (f : string -> bool) =
        testCase "test119" <| fun () ->
            Expect.isTrue ((f @"NotAnEmail") = Invalid) "Expcect Invalid"

    let test120 (f : string -> bool) =
        testCase "test120" <| fun () ->
            Expect.isTrue ((f @"@NotAnEmail") = Invalid) "Expcect Invalid"

    let test121 (f : string -> bool) =
    //"test\\blah"@iana.org
        testCase "test121" <| fun () ->
            Expect.isTrue ((f "\"test\\\\blah\"@iana.org") = Valid) "Expcect Valid"

    let test122 (f : string -> bool) =
    //"test\blah"@iana.org
        testCase "test122" <| fun () ->
            Expect.isTrue ((f "\"test\\blah\"@iana.org") = Valid) "Expcect Valid"

    let test123 (f : string -> bool) =
    //"test\
blah"@iana.org
        testCase "test123" <| fun () ->
            Expect.isTrue ((f "\"test\\
blah\"@iana.org") = Valid) "Expcect Valid"

    let test124 (f : string -> bool) =
    //"test
blah"@iana.org
        testCase "test124" <| fun () ->
            Expect.isTrue ((f "\"test
blah\"@iana.org") = Invalid) "Expcect Invalid"

    let test125 (f : string -> bool) =
    //"test\"blah"@iana.org
        testCase "test125" <| fun () ->
            Expect.isTrue ((f "\"test\\\"blah\"@iana.org") = Valid) "Expcect Valid"

    let test126 (f : string -> bool) =
    //"test"blah"@iana.org
        testCase "test126" <| fun () ->
            Expect.isTrue ((f "\"test\"blah\"@iana.org") = Invalid) "Expcect Invalid"

    let test127 (f : string -> bool) =
        testCase "test127" <| fun () ->
            Expect.isTrue ((f @"customer/department@iana.org") = Valid) "Expcect Valid"

    let test128 (f : string -> bool) =
        testCase "test128" <| fun () ->
            Expect.isTrue ((f @"_Yosemite.Sam@iana.org") = Valid) "Expcect Valid"

    let test129 (f : string -> bool) =
        testCase "test129" <| fun () ->
            Expect.isTrue ((f @"~@iana.org") = Valid) "Expcect Valid"

    let test130 (f : string -> bool) =
        testCase "test130" <| fun () ->
         Expect.isTrue ((f @".wooly@iana.org") = Invalid) "Expcect Invalid"

    let test131 (f : string -> bool) =
        testCase "test131" <| fun () ->
            Expect.isTrue ((f @"wo..oly@iana.org") = Invalid) "Expcect Invalid"

    let test132 (f : string -> bool) =
        testCase "test132" <| fun () ->
            Expect.isTrue ((f @"pootietang.@iana.org") = Invalid) "Expcect Invalid"

    let test133 (f : string -> bool) =
        testCase "test133" <| fun () ->
         Expect.isTrue ((f @".@iana.org") = Invalid) "Expcect Invalid"

    let test134 (f : string -> bool) =
    //"Austin@Powers"@iana.org
        testCase "test134" <| fun () ->
            Expect.isTrue ((f "\"Austin@Powers\"@iana.org") = Valid) "Expcect Valid"

    let test135 (f : string -> bool) =
        testCase "test135" <| fun () ->
            Expect.isTrue ((f @"Ima.Fool@iana.org") = Valid) "Expcect Valid"

//following 2 are duplicates in the source
    let test136 (f : string -> bool) =
    //"Ima.Fool"@iana.org
        testCase "test136" <| fun () ->
            Expect.isTrue ((f "\"Ima.Fool\"@iana.org") = Valid) "Expcect Valid"

    let test137 (f : string -> bool) =
    //"Ima Fool"@iana.org
        testCase "test137" <| fun () ->
            Expect.isTrue ((f "\"Ima Fool\"@iana.org") = Valid) "Expcect Valid"

    let test138 (f : string -> bool) =
        testCase "test138" <| fun () ->
            Expect.isTrue ((f @"Ima Fool@iana.org") = Invalid) "Expcect Invalid"

    let test139 (f : string -> bool) =
        testCase "test139" <| fun () ->
            Expect.isTrue ((f @"phil.h\@\@ck@haacked.com") = Invalid) "Expcect Invalid"

    let test140 (f : string -> bool) =
    //"first"."last"@iana.org
        testCase "test140" <| fun () ->
            Expect.isTrue ((f "\"first\".\"last\"@iana.org") = Valid) "Expcect Valid"

    let test141 (f : string -> bool) =
    //"first".middle."last"@iana.org
        testCase "test141" <| fun () ->
            Expect.isTrue ((f "\"first\".middle.\"last\"@iana.org") = Valid) "Expcect Valid"

    let test142 (f : string -> bool) =
    //"first\\"last"@iana.org
        testCase "test142" <| fun () ->
            Expect.isTrue ((f "\"first\\\\\"last\"@iana.org") = Invalid) "Expcect Invalid"

    let test143 (f : string -> bool) =
    //"first".last@iana.org
        testCase "test143" <| fun () ->
            Expect.isTrue ((f "\"first\".last@iana.org") = Valid) "Expcect Valid"

    let test144 (f : string -> bool) =
    //first."last"@iana.org
        testCase "test144" <| fun () ->
            Expect.isTrue ((f "first.\"last\"@iana.org") = Valid) "Expcect Valid"

    let test145 (f : string -> bool) =
    //"first"."middle"."last"@iana.org
        testCase "test145" <| fun () ->
            Expect.isTrue ((f "\"first\".\"middle\".\"last\"@iana.org") = Valid) "Expcect Valid"

    let test146 (f : string -> bool) =
    //"first.middle"."last"@iana.org
        testCase "test146" <| fun () ->
            Expect.isTrue ((f "\"first.middle\".\"last\"@iana.org") = Valid) "Expcect Valid"

    let test147 (f : string -> bool) =
    //"first.middle.last"@iana.org
        testCase "test147" <| fun () ->
            Expect.isTrue ((f "\"first.middle.last\"@iana.org") = Valid) "Expcect Valid"

    let test148 (f : string -> bool) =
    //"first..last"@iana.org
        testCase "test148" <| fun () ->
            Expect.isTrue ((f "\"first..last\"@iana.org") = Valid) "Expcect Valid"

    let test149 (f : string -> bool) =
        testCase "test149" <| fun () ->
            Expect.isTrue ((f @"foo@[\1.2.3.4]") = Invalid) "Expcect Invalid"

    let test150 (f : string -> bool) =
    //"first\\\"last"@iana.org
        testCase "test150" <| fun () ->
            Expect.isTrue ((f "\"first\\\\\\\"last\"@iana.org") = Valid) "Expcect Valid"

    let test151 (f : string -> bool) =
    //first."mid\dle"."last"@iana.org
        testCase "test151" <| fun () ->
            Expect.isTrue ((f "first.\"mid\\dle\".\"last\"@iana.org") = Valid) "Expcect Valid"

    let test152 (f : string -> bool) =
        testCase "test152" <| fun () ->
            Expect.isTrue ((f @"Test.
 Folding.
 Whitespace@iana.org") = Valid) "Expcect Valid"

    let test153 (f : string -> bool) =
    //first."".last@iana.org
        testCase "test153" <| fun () ->
            Expect.isTrue ((f "first.\"\".last@iana.org") = Invalid) "Expcect Invalid"

    let test154 (f : string -> bool) =
        testCase "test154" <| fun () ->
            Expect.isTrue ((f @"first\last@iana.org") = Invalid) "Expcect Invalid"

    let test155 (f : string -> bool) =
        testCase "test155" <| fun () ->
            Expect.isTrue ((f @"Abc\@def@iana.org") = Invalid) "Expcect Invalid"

    let test156 (f : string -> bool) =
        testCase "test156" <| fun () ->
            Expect.isTrue ((f @"Fred\ Bloggs@iana.org") = Invalid) "Expcect Invalid"

    let test157 (f : string -> bool) =
        testCase "test157" <| fun () ->
            Expect.isTrue ((f @"Joe.\\Blow@iana.org") = Invalid) "Expcect Invalid"

    let test158 (f : string -> bool) =
        testCase "test158" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:1111:2222:3333:4444:5555:6666:12.34.567.89]") = Invalid) "Expcect Invalid"

    let test159 (f : string -> bool) =
    //"test\
 blah"@iana.org
        testCase "test159" <| fun () ->
            Expect.isTrue ((f "\"test\
 blah\"@iana.org") = Invalid) "Expcect Invalid"

    let test160 (f : string -> bool) =
    //"test
 blah"@iana.org
        testCase "test160" <| fun () ->
            Expect.isTrue ((f "\"test
 blah\"@iana.org") = Valid) "Expcect Valid"

    let test161 (f : string -> bool) =
        testCase "test161" <| fun () ->
            Expect.isTrue ((f @"{^c\@**Dog^}@cartoon.com") = Invalid) "Expcect Invalid"

    let test162 (f : string -> bool) =
        testCase "test162" <| fun () ->
            Expect.isTrue ((f @"(foo)cal(bar)@(baz)iamcal.com(quux)") = Valid) "Expcect Valid"

    let test163 (f : string -> bool) =
        testCase "test163" <| fun () ->
            Expect.isTrue ((f @"cal@iamcal(woo).(yay)com") = Valid) "Expcect Valid"

    let test164 (f : string -> bool) =
    //"foo"(yay)@(hoopla)[1.2.3.4]
        testCase "test164" <| fun () ->
            Expect.isTrue ((f "\"foo\"(yay)@(hoopla)[1.2.3.4]") = Invalid) "Expcect Invalid"

    let test165 (f : string -> bool) =
        testCase "test165" <| fun () ->
            Expect.isTrue ((f @"cal(woo(yay)hoopla)@iamcal.com") = Valid) "Expcect Valid"

    let test166 (f : string -> bool) =
        testCase "test166" <| fun () ->
            Expect.isTrue ((f @"cal(foo\@bar)@iamcal.com") = Valid) "Expcect Valid"

    let test167 (f : string -> bool) =
        testCase "test167" <| fun () ->
            Expect.isTrue ((f @"cal(foo\)bar)@iamcal.com") = Valid) "Expcect Valid"

    let test168 (f : string -> bool) =
        testCase "test168" <| fun () ->
            Expect.isTrue ((f @"cal(foo(bar)@iamcal.com") = Invalid) "Expcect Invalid"

    let test169 (f : string -> bool) =
        testCase "test196" <| fun () ->
            Expect.isTrue ((f @"cal(foo)bar)@iamcal.com") = Invalid) "Expcect Invalid"

    let test170(f : string -> bool) =
        testCase "test170" <| fun () ->
            Expect.isTrue ((f @"cal(foo\)@iamcal.com") = Invalid) "Expcect Invalid"

    let test171 (f : string -> bool) =
        testCase "test171" <| fun () ->
            Expect.isTrue ((f @"first().last@iana.org") = Valid) "Expcect Valid"

    let test172 (f : string -> bool) =
        testCase "test172" <| fun () ->
            Expect.isTrue ((f @"first.(
 middle
 )last@iana.org") = Valid) "Expcect Valid"

    let test173 (f : string -> bool) =
        testCase "test173" <| fun () ->
            Expect.isTrue ((f @"first(12345678901234567890123456789012345678901234567890)last@(1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890)iana.org")
                = Invalid) "Expcect Invalid"

    let test174 (f : string -> bool) =
    //first(Welcome to
 the ("wonderful" (!)) world
 of email)@iana.org
        testCase "test174" <| fun () ->
            Expect.isTrue ((f "first(Welcome to
 the (\"wonderful\" (!)) world
 of email)@iana.org")
                = Valid) "Expcect Valid"

    let test175 (f : string -> bool) =
        testCase "test175" <| fun () ->
            Expect.isTrue ((f @"pete(his account)@silly.test(his host)") = Valid) "Expcect Valid"

    let test176 (f : string -> bool) =
        testCase "test176" <| fun () ->
            Expect.isTrue ((f @"c@(Chris's host.)public.example") = Valid) "Expcect Valid"

    let test177(f : string -> bool) =
        testCase "test177" <| fun () ->
            Expect.isTrue ((f @"jdoe@machine(comment).  example") = Valid) "Expcect Valid"

    let test178 (f : string -> bool) =
        testCase "test178" <| fun () ->
            Expect.isTrue ((f @"1234   @   local(blah)  .machine .example") = Valid) "Expcect Valid"

    let test179 (f : string -> bool) =
        testCase "test179" <| fun () ->
            Expect.isTrue ((f @"first(middle)last@iana.org") = Invalid) "Expcect Invalid"

    let test180 (f : string -> bool) =
        testCase "test180" <| fun () ->
            Expect.isTrue ((f @"first(abc.def).last@iana.org") = Valid) "Expcect Valid"

    let test181 (f : string -> bool) =
    //first(a"bc.def).last@iana.org
        testCase "test181" <| fun () ->
            Expect.isTrue ((f "first(a\"bc.def).last@iana.org") = Valid) "Expcect Valid"

    let test182 (f : string -> bool) =
    //first.(")middle.last(")@iana.org
        testCase "test182" <| fun () ->
            Expect.isTrue ((f "first.(\")middle.last(\")@iana.org") = Valid) "Expcect Valid"

    let test183 (f : string -> bool) =
    //first(abc("def".ghi).mno)middle(abc("def".ghi).mno).last@(abc("def".ghi).mno)example(abc("def".ghi).mno).(abc("def".ghi).mno)com(abc("def".ghi).mno)
        testCase "test183" <| fun () ->
            Expect.isTrue ((f "first(abc(\"def\".ghi).mno)middle(abc(\"def\".ghi).mno).last@(abc(\"def\".ghi).mno)example(abc(\"def\".ghi).mno).(abc(\"def\".ghi).mno)com(abc(\"def\".ghi).mno)")
                = Invalid) "Expcect Invalid"

    let test184 (f : string -> bool) =
        testCase "test184" <| fun () ->
            Expect.isTrue ((f @"first(abc\(def)@iana.org") = Valid) "Expcect Valid"

    let test185 (f : string -> bool) =
        testCase "test185" <| fun () ->
            Expect.isTrue ((f @"first.last@x(1234567890123456789012345678901234567890123456789012345678901234567890).com")
                = Valid) "Expcect Valid"

    let test186 (f : string -> bool) =
        testCase "test186" <| fun () ->
            Expect.isTrue ((f @"a(a(b(c)d(e(f))g)h(i)j)@iana.org") = Valid) "Expcect Valid"

    let test187 (f : string -> bool) =
        testCase "test187" <| fun () ->
            Expect.isTrue ((f @"a(a(b(c)d(e(f))g)(h(i)j)@iana.org") = Invalid) "Expcect Invalid"

    let test188 (f : string -> bool) =
        testCase "test188" <| fun () ->
            Expect.isTrue ((f @"name.lastname@domain.com") = Valid) "Expcect Valid"

    let test189 (f : string -> bool) =
        testCase "test189" <| fun () ->
            Expect.isTrue ((f @".@") = Invalid) "Expcect Invalid"

    let test190 (f : string -> bool) =
        testCase "test190" <| fun () ->
            Expect.isTrue ((f @"a@b") = Valid) "Expcect Valid"

    let test191 (f : string -> bool) =
        testCase "test191" <| fun () ->
            Expect.isTrue ((f @"@bar.com") = Invalid) "Expcect Invalid"

    let test192 (f : string -> bool) =
        testCase "test192" <| fun () ->
            Expect.isTrue ((f @"@@bar.com") = Invalid) "Expcect Invalid"

    let test193 (f : string -> bool) =
        testCase "test193" <| fun () ->
            Expect.isTrue ((f @"a@bar.com") = Valid) "Expcect Valid"

    let test194 (f : string -> bool) =
        testCase "test194" <| fun () ->
            Expect.isTrue ((f @"aaa.com") = Invalid) "Expcect Invalid"

    let test195 (f : string -> bool) =
        testCase "test195" <| fun () ->
            Expect.isTrue ((f @"aaa@.com") = Invalid) "Expcect Invalid"

    let test196 (f : string -> bool) =
        testCase "test196" <| fun () ->
            Expect.isTrue ((f @"aaa@.123") = Invalid) "Expcect Invalid"

    let test197 (f : string -> bool) =
        testCase "test197" <| fun () ->
            Expect.isTrue ((f @"aaa@[123.123.123.123]") = Valid) "Expcect Valid"

    let test198 (f : string -> bool) =
        testCase "test198" <| fun () ->
            Expect.isTrue ((f @"aaa@[123.123.123.123]a") = Invalid) "Expcect Invalid"

    let test199 (f : string -> bool) =
        testCase "test199" <| fun () ->
            Expect.isTrue ((f @"aaa@[123.123.123.333]") = Invalid) "Expcect Invalid"

    let test200 (f : string -> bool) =
        testCase "test200" <| fun () ->
            Expect.isTrue ((f @"a@bar.com.") = Invalid) "Expcect Invalid"

    let test201 (f : string -> bool) =
        testCase "test201" <| fun () ->
            Expect.isTrue ((f @"a@bar") = Valid) "Expcect Valid"

    let test202 (f : string -> bool) =
        testCase "test202" <| fun () ->
            Expect.isTrue ((f @"a-b@bar.com") = Valid) "Expcect Valid"

    let test203 (f : string -> bool) =
        testCase "test203" <| fun () ->
            Expect.isTrue ((f @"+@b.c") = Valid) "Expcect Valid"

    let test204 (f : string -> bool) =
        testCase "test204" <| fun () ->
            Expect.isTrue ((f @"+@b.com") = Valid) "Expcect Valid"

    let test205 (f : string -> bool) =
        testCase "test205" <| fun () ->
            Expect.isTrue ((f @"a@-b.com") = Invalid) "Expcect Invalid"

    let test206 (f : string -> bool) =
        testCase "test206" <| fun () ->
            Expect.isTrue ((f @"a@b-.com") = Invalid) "Expcect Invalid"

    let test207 (f : string -> bool) =
        testCase "test207" <| fun () ->
            Expect.isTrue ((f @"-@..com") = Invalid) "Expcect Invalid"

    let test208 (f : string -> bool) =
        testCase "test208" <| fun () ->
            Expect.isTrue ((f @"-@a..com") = Invalid) "Expcect Invalid"

    let test209 (f : string -> bool) =
        testCase "test209" <| fun () ->
            Expect.isTrue ((f @"a@b.co-foo.uk") = Valid) "Expcect Valid"

    let test210 (f : string -> bool) =
    //"hello my name is"@stutter.com
        testCase "test210" <| fun () ->
            Expect.isTrue ((f "\"hello my name is\"@stutter.com") = Valid) "Expcect Valid"

    let test211 (f : string -> bool) =
    //"Test \"Fail\" Ing"@iana.org
        testCase "test211" <| fun () ->
            Expect.isTrue ((f "\"Test \\\"Fail\\\" Ing\"@iana.org") = Valid) "Expcect Valid"

    let test212 (f : string -> bool) =
        testCase "test212" <| fun () ->
            Expect.isTrue ((f @"valid@about.museum") = Valid) "Expcect Valid"

    let test213 (f : string -> bool) =
        testCase "test213" <| fun () ->
            Expect.isTrue ((f @"Invalid@about.museum-") = Invalid) "Expcect Invalid"

    let test214 (f : string -> bool) =
        testCase "test214" <| fun () ->
            Expect.isTrue ((f @"shaitan@my-domain.thisisminekthx") = Valid) "Expcect Valid"

    let test215 (f : string -> bool) =
        testCase "test215" <| fun () ->
            Expect.isTrue ((f @"test@...........com") = Invalid) "Expcect Invalid"

    let test216 (f : string -> bool) =
        testCase "test216" <| fun () ->
            Expect.isTrue ((f @"foobar@192.168.0.1") = Valid) "Expcect Valid"

    let test217 (f : string -> bool) =
    //"Joe\\Blow"@iana.org
        testCase "test217" <| fun () ->
            Expect.isTrue ((f "\"Joe\\\\Blow\"@iana.org") = Valid) "Expcect Valid"

    let test218 (f : string -> bool) =
        testCase "test218" <| fun () ->
            Expect.isTrue ((f @"Invalid \
 Folding \
 Whitespace@iana.org") = Invalid) "Expcect Invalid"

    let test219 (f : string -> bool) =
        testCase "test219" <| fun () ->
            Expect.isTrue ((f @"HM2Kinsists@(that comments are allowed)this.is.ok") = Valid) "Expcect Valid"

    let test220 (f : string -> bool) =
        testCase "test220" <| fun () ->
            Expect.isTrue ((f @"user%uucp!path@berkeley.edu") = Valid) "Expcect Valid"

    let test221 (f : string -> bool) =
    //"first(last)"@iana.org
        testCase "test221" <| fun () ->
            Expect.isTrue ((f "\"first(last)\"@iana.org") = Valid) "Expcect Valid"

    let test222 (f : string -> bool) =
        testCase "test222" <| fun () ->
            Expect.isTrue ((f @"
 (
 x
 )
 first
 (
 x
 )
 .
 (
 x)
 last
 (  x
 )
 @iana.org")
                = Valid) "Expcect Valid"

    let test223 (f : string -> bool) =
        testCase "test223" <| fun () ->
            Expect.isTrue ((f @"first.last @iana.org") = Valid) "Expcect Valid"

    let test224 (f : string -> bool) =
        testCase "test224" <| fun () ->
            Expect.isTrue ((f @"test.

 obs@syntax.com") = Valid) "Expcect Valid"

    let test225 (f : string -> bool) =
        testCase "test225" <| fun () ->
            Expect.isTrue ((f @"test.

 obs@syntax.com") = Invalid) "Expcect Invalid"

    let test226 (f : string -> bool) =  //\u0000
    //"Unicode NULL \␀"@char.com
        testCase "test226" <| fun () ->
            Expect.isTrue ((f "\"Unicode NULL \\\u0000\"@char.com") = Valid) "Expcect Valid"

    let test227 (f : string -> bool) =
    //"Unicode NULL ␀"@char.com
        testCase "test227" <| fun () ->
            Expect.isTrue ((f "\"Unicode NULL \u0000\"@char.com") = Invalid) "Expcect Invalid"

    let test228 (f : string -> bool) =
    //Unicode NULL \␀@char.com
        testCase "test228" <| fun () ->
            Expect.isTrue ((f "Unicode NULL \\\u0000@char.com") = Invalid) "Expcect Invalid"

    let test229 (f : string -> bool) =
        testCase "test229" <| fun () ->
            Expect.isTrue ((f @"cdburgess+!#$%&'*-/=?+_{}|~test@gmail.com") = Valid) "Expcect Valid"

    let test230 (f : string -> bool) =
        testCase "test230" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::a2:a3:a4:b1:b2:b3:b4]") = Valid) "Expcect Valid"

    let test231 (f : string -> bool) =
        testCase "test231" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:a3:a4:b1:b2:b3::]") = Valid) "Expcect Valid"

    let test232 (f : string -> bool) =
        testCase "test232" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::]") = Invalid) "Expcect Invalid"

    let test233 (f : string -> bool) =
        testCase "test233" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::]") = Valid) "Expcect Valid"

    let test234 (f : string -> bool) =
        testCase "test234" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::::]") = Invalid) "Expcect Invalid"

    let test235 (f : string -> bool) =
        testCase "test235" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::b4]") = Invalid) "Expcect Invalid"

    let test236 (f : string -> bool) =
        testCase "test236" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::b4]") = Valid) "Expcect Valid"

    let test237 (f : string -> bool) =
        testCase "test237" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::::b4]") = Invalid) "Expcect Invalid"

    let test238 (f : string -> bool) =
        testCase "test238" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::b3:b4]") = Invalid) "Expcect Invalid"

    let test239 (f : string -> bool) =
        testCase "test239" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::b3:b4]") = Valid) "Expcect Valid"

    let test240(f : string -> bool) =
        testCase "test240" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::::b3:b4]") = Invalid) "Expcect Invalid"

    let test241 (f : string -> bool) =
        testCase "test241" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::b4]") = Valid) "Expcect Valid"

    let test242 (f : string -> bool) =
        testCase "test242" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:::b4]") = Invalid) "Expcect Invalid"

    let test243 (f : string -> bool) =
        testCase "test243" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:]") = Invalid) "Expcect Invalid"

    let test244 (f : string -> bool) =
        testCase "test244" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::]") = Valid) "Expcect Valid"

    let test245 (f : string -> bool) =
        testCase "test245" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:::]") = Invalid) "Expcect Invalid"

    let test246 (f : string -> bool) =
        testCase "test246" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:]") = Invalid) "Expcect Invalid"

    let test247 (f : string -> bool) =
        testCase "test247" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2::]") = Valid) "Expcect Valid"

    let test248 (f : string -> bool) =
        testCase "test248" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:::]") = Invalid) "Expcect Invalid"

    let test249 (f : string -> bool) =
        testCase "test249" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:cdef::]") = Valid) "Expcect Valid"

    let test250 (f : string -> bool) =
        testCase "test250" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:CDEF::]") = Valid) "Expcect Valid"

    let test251 (f : string -> bool) =
        testCase "test251" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::a3:a4:b1:ffff:11.22.33.44]") = Valid) "Expcect Valid"

    let test252 (f : string -> bool) =
        testCase "test252" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:::a2:a3:a4:b1:ffff:11.22.33.44]") = Valid) "Expcect Valid"

    let test253 (f : string -> bool) =
        testCase "test253" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:a3:a4::11.22.33.44]") = Valid) "Expcect Valid"

    let test254 (f : string -> bool) =
        testCase "test254" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:a3:a4:b1::11.22.33.44]") = Valid) "Expcect Valid"

    let test255 (f : string -> bool) =
        testCase "test255" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test256 (f : string -> bool) =
        testCase "test256" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test257 (f : string -> bool) =
        testCase "test257" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:11.22.33.44]") = Invalid) "Expcect Invalid"

    let test258 (f : string -> bool) =
        testCase "test258" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::11.22.33.44]") = Valid) "Expcect Valid"

    let test259 (f : string -> bool) =
        testCase "test259" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test260 (f : string -> bool) =
        testCase "test260" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2::11.22.33.44]") = Valid) "Expcect Valid"

    let test261 (f : string -> bool) =
        testCase "test261" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test262 (f : string -> bool) =
        testCase "test262" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:cdef::11.22.33.44]") = Valid) "Expcect Valid"

    let test263 (f : string -> bool) =
        testCase "test263" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:cdef::11.22.33.xx]") = Invalid) "Expcect Invalid"

    let test264 (f : string -> bool) =
        testCase "test264" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:CDEF::11.22.33.44]") = Valid) "Expcect Valid"

    let test265 (f : string -> bool) =
        testCase "test265" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:0123:4567:89ab:CDEFF::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test266 (f : string -> bool) =
        testCase "test266" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::a4:b1::b4:11.22.33.44]") = Invalid) "Expcect Invalid"

    let test267 (f : string -> bool) =
        testCase "test267" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::11.22.33]") = Invalid) "Expcect Invalid"

    let test268 (f : string -> bool) =
        testCase "test268" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::11.22.33.44.55]") = Invalid) "Expcect Invalid"

    let test269 (f : string -> bool) =
        testCase "test269" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::b211.22.33.44]") = Invalid) "Expcect Invalid"

    let test270 (f : string -> bool) =
        testCase "test270" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::b2:11.22.33.44]") = Valid) "Expcect Valid"

    let test271 (f : string -> bool) =
        testCase "test271" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::b2::11.22.33.44]") = Invalid) "Expcect Invalid"

    let test272 (f : string -> bool) =
        testCase "test272" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1::b3:]") = Invalid) "Expcect Invalid"

    let test273 (f : string -> bool) =
        testCase "test273" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::a2::b4]") = Invalid) "Expcect Invalid"

    let test274 (f : string -> bool) =
        testCase "test274" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:a3:a4:b1:b2:b3:]") = Invalid) "Expcect Invalid"

    let test275 (f : string -> bool) =
        testCase "test275" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6::a2:a3:a4:b1:b2:b3:b4]") = Invalid) "Expcect Invalid"

    let test276 (f : string -> bool) =
        testCase "test276" <| fun () ->
            Expect.isTrue ((f @"first.last@[IPv6:a1:a2:a3:a4::b1:b2:b3:b4]") = Invalid) "Expcect Invalid"

    let test277 (f : string -> bool) =
        testCase "test277" <| fun () ->
            Expect.isTrue ((f @"test@test.com") = Valid) "Expcect Valid"

    let test278 (f : string -> bool) =
        testCase "test278" <| fun () ->
            Expect.isTrue ((f @"test@example.com
") = Invalid) "Expcect Invalid"

    let test279 (f : string -> bool) =
        testCase "test279" <| fun () ->
            Expect.isTrue ((f @"test@xn--example.com") = Valid) "Expcect Valid"

    let test280 (f : string -> bool) =
        testCase "test280" <| fun () ->
            Expect.isTrue ((f @"test@Bücher.ch") = Valid) "Expcect Valid"


text:
This file is in the `lib` directory.

Any **libraries** on which your project depends and which are **NOT managed via NuGet** should be kept **in this directory**.
This typically includes custom builds of third-party software, private (i.e. to a company) codebases, and native libraries.

---
NOTE:

This file is a placeholder, used to preserve directory structure in Git.

This file does not need to be edited.

repo_name: jackfoxy/FsRegEx

repo_language: F#

mime_type: text/plain


text:
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <!-- Prevent dotnet template engine to parse this file -->
  <!--/-:cnd:noEmit-->
  <PropertyGroup>
    <!-- make MSBuild track this file for incremental builds. -->
    <!-- ref https://blogs.msdn.microsoft.com/msbuild/2005/09/26/how-to-ensure-changes-to-a-custom-target-file-prompt-a-rebuild/ -->
    <MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
    <!-- Mark that this target file has been loaded.  -->
    <IsPaketRestoreTargetsFileLoaded>true</IsPaketRestoreTargetsFileLoaded>
    <PaketToolsPath>$(MSBuildThisFileDirectory)</PaketToolsPath>
    <PaketRootPath>$(MSBuildThisFileDirectory)..\</PaketRootPath>
    <PaketRestoreCacheFile>$(PaketRootPath)paket-files\paket.restore.cached</PaketRestoreCacheFile>
    <PaketLockFilePath>$(PaketRootPath)paket.lock</PaketLockFilePath>
    <MonoPath Condition="'$(MonoPath)' == '' And Exists('/Library/Frameworks/Mono.framework/Commands/mono')">/Library/Frameworks/Mono.framework/Commands/mono</MonoPath>
    <MonoPath Condition="'$(MonoPath)' == ''">mono</MonoPath>
    <!-- Paket command -->
    <PaketExePath Condition=" '$(PaketExePath)' == '' AND Exists('$(PaketRootPath)paket.exe')">$(PaketRootPath)paket.exe</PaketExePath>
    <PaketExePath Condition=" '$(PaketExePath)' == '' ">$(PaketToolsPath)paket.exe</PaketExePath>
    <PaketCommand Condition=" '$(OS)' == 'Windows_NT'">"$(PaketExePath)"</PaketCommand>
    <PaketCommand Condition=" '$(OS)' != 'Windows_NT' ">$(MonoPath) --runtime=v4.0.30319 "$(PaketExePath)"</PaketCommand>

    <!-- .net core fdd -->
    <_PaketExeExtension>$([System.IO.Path]::GetExtension("$(PaketExePath)"))</_PaketExeExtension>
    <PaketCommand Condition=" '$(_PaketExeExtension)' == '.dll' ">dotnet "$(PaketExePath)"</PaketCommand>

    <!-- no extension is a shell script -->
    <PaketCommand Condition=" '$(_PaketExeExtension)' == '' ">"$(PaketExePath)"</PaketCommand>

    <PaketBootStrapperExePath Condition=" '$(PaketBootStrapperExePath)' == '' AND Exists('$(PaketRootPath)paket.bootstrapper.exe')">$(PaketRootPath)paket.bootstrapper.exe</PaketBootStrapperExePath>
    <PaketBootStrapperExePath Condition=" '$(PaketBootStrapperExePath)' == '' ">$(PaketToolsPath)paket.bootstrapper.exe</PaketBootStrapperExePath>
    <PaketBootStrapperCommand Condition=" '$(OS)' == 'Windows_NT'">"$(PaketBootStrapperExePath)"</PaketBootStrapperCommand>
    <PaketBootStrapperCommand Condition=" '$(OS)' != 'Windows_NT' ">$(MonoPath) --runtime=v4.0.30319 "$(PaketBootStrapperExePath)"</PaketBootStrapperCommand>

    <!-- Disable automagic references for F# dotnet sdk -->
    <!-- This will not do anything for other project types -->
    <!-- see https://github.com/fsharp/fslang-design/blob/master/RFCs/FS-1032-fsharp-in-dotnet-sdk.md -->
    <DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
    <DisableImplicitSystemValueTupleReference>true</DisableImplicitSystemValueTupleReference>
  </PropertyGroup>

  <Target Name="PaketRestore" Condition="'$(PaketRestoreDisabled)' != 'True'" BeforeTargets="_GenerateDotnetCliToolReferenceSpecs;_GenerateProjectRestoreGraphPerFramework;_GenerateRestoreGraphWalkPerFramework;CollectPackageReferences" >

    <!-- Step 1 Check if lockfile is properly restored -->
    <PropertyGroup>
      <PaketRestoreRequired>true</PaketRestoreRequired>
      <NoWarn>$(NoWarn);NU1603;NU1604;NU1605;NU1608</NoWarn>
    </PropertyGroup>

    <!-- Because ReadAllText is slow on osx/linux, try to find shasum and awk -->
    <PropertyGroup>
      <PaketRestoreCachedHasher Condition="'$(OS)' != 'Windows_NT' And '$(PaketRestoreCachedHasher)' == '' And Exists('/usr/bin/shasum') And Exists('/usr/bin/awk')">/usr/bin/shasum "$(PaketRestoreCacheFile)" | /usr/bin/awk '{ print $1 }'</PaketRestoreCachedHasher>
      <PaketRestoreLockFileHasher Condition="'$(OS)' != 'Windows_NT' And '$(PaketRestoreLockFileHash)' == '' And Exists('/usr/bin/shasum') And Exists('/usr/bin/awk')">/usr/bin/shasum "$(PaketLockFilePath)" | /usr/bin/awk '{ print $1 }'</PaketRestoreLockFileHasher>
    </PropertyGroup>

    <!-- If shasum and awk exist get the hashes -->
    <Exec StandardOutputImportance="Low" Condition=" '$(PaketRestoreCachedHasher)' != '' " Command="$(PaketRestoreCachedHasher)" ConsoleToMSBuild='true'>
      <Output TaskParameter="ConsoleOutput" PropertyName="PaketRestoreCachedHash" />
    </Exec>
    <Exec StandardOutputImportance="Low" Condition=" '$(PaketRestoreLockFileHasher)' != '' " Command="$(PaketRestoreLockFileHasher)" ConsoleToMSBuild='true'>
      <Output TaskParameter="ConsoleOutput" PropertyName="PaketRestoreLockFileHash" />
    </Exec>

    <!-- Debug whats going on -->
    <Message Importance="low" Text="calling paket restore with targetframework=$(TargetFramework) targetframeworks=$(TargetFrameworks)" />

    <PropertyGroup Condition="Exists('$(PaketRestoreCacheFile)') ">
      <!-- if no hash has been done yet fall back to just reading in the files and comparing them -->
      <PaketRestoreCachedHash Condition=" '$(PaketRestoreCachedHash)' == '' ">$([System.IO.File]::ReadAllText('$(PaketRestoreCacheFile)'))</PaketRestoreCachedHash>
      <PaketRestoreLockFileHash Condition=" '$(PaketRestoreLockFileHash)' == '' ">$([System.IO.File]::ReadAllText('$(PaketLockFilePath)'))</PaketRestoreLockFileHash>
      <PaketRestoreRequired>true</PaketRestoreRequired>
      <PaketRestoreRequired Condition=" '$(PaketRestoreLockFileHash)' == '$(PaketRestoreCachedHash)' ">false</PaketRestoreRequired>
      <PaketRestoreRequired Condition=" '$(PaketRestoreLockFileHash)' == '' ">true</PaketRestoreRequired>
    </PropertyGroup>

    <!-- Do a global restore if required -->
    <Exec Command='$(PaketBootStrapperCommand)' Condition="Exists('$(PaketBootStrapperExePath)') AND !(Exists('$(PaketExePath)'))" ContinueOnError="false" />
    <Exec Command='$(PaketCommand) restore' Condition=" '$(PaketRestoreRequired)' == 'true' " ContinueOnError="false" />

    <!-- Step 2 Detect project specific changes -->
    <ItemGroup>
      <MyTargetFrameworks Condition="'$(TargetFramework)' != '' " Include="$(TargetFramework)"></MyTargetFrameworks>
      <!-- Don't include all frameworks when msbuild explicitly asks for a single one -->
      <MyTargetFrameworks Condition="'$(TargetFrameworks)' != '' AND '$(TargetFramework)' == '' " Include="$(TargetFrameworks)"></MyTargetFrameworks>
      <PaketResolvedFilePaths Include="@(MyTargetFrameworks -> '$(MSBuildProjectDirectory)\obj\$(MSBuildProjectFile).%(Identity).paket.resolved')"></PaketResolvedFilePaths>
    </ItemGroup>
    <Message Importance="low" Text="MyTargetFrameworks=@(MyTargetFrameworks) PaketResolvedFilePaths=@(PaketResolvedFilePaths)" />
    <PropertyGroup>
      <PaketReferencesCachedFilePath>$(MSBuildProjectDirectory)\obj\$(MSBuildProjectFile).paket.references.cached</PaketReferencesCachedFilePath>
      <!-- MyProject.fsproj.paket.references has the highest precedence -->
      <PaketOriginalReferencesFilePath>$(MSBuildProjectFullPath).paket.references</PaketOriginalReferencesFilePath>
      <!-- MyProject.paket.references -->
      <PaketOriginalReferencesFilePath Condition=" !Exists('$(PaketOriginalReferencesFilePath)')">$(MSBuildProjectDirectory)\$(MSBuildProjectName).paket.references</PaketOriginalReferencesFilePath>
      <!-- paket.references -->
      <PaketOriginalReferencesFilePath Condition=" !Exists('$(PaketOriginalReferencesFilePath)')">$(MSBuildProjectDirectory)\paket.references</PaketOriginalReferencesFilePath>

      <DoAllResolvedFilesExist>false</DoAllResolvedFilesExist>
      <DoAllResolvedFilesExist Condition="Exists(%(PaketResolvedFilePaths.Identity))">true</DoAllResolvedFilesExist>
      <PaketRestoreRequired>true</PaketRestoreRequired>
      <PaketRestoreRequiredReason>references-file-or-cache-not-found</PaketRestoreRequiredReason>
    </PropertyGroup>

    <!-- Step 2 a Detect changes in references file -->
    <PropertyGroup Condition="Exists('$(PaketOriginalReferencesFilePath)') AND Exists('$(PaketReferencesCachedFilePath)') ">
      <PaketRestoreCachedHash>$([System.IO.File]::ReadAllText('$(PaketReferencesCachedFilePath)'))</PaketRestoreCachedHash>
      <PaketRestoreReferencesFileHash>$([System.IO.File]::ReadAllText('$(PaketOriginalReferencesFilePath)'))</PaketRestoreReferencesFileHash>
      <PaketRestoreRequiredReason>references-file</PaketRestoreRequiredReason>
      <PaketRestoreRequired Condition=" '$(PaketRestoreReferencesFileHash)' == '$(PaketRestoreCachedHash)' ">false</PaketRestoreRequired>
    </PropertyGroup>

    <PropertyGroup Condition="!Exists('$(PaketOriginalReferencesFilePath)') AND !Exists('$(PaketReferencesCachedFilePath)') ">
      <!-- If both don't exist there is nothing to do. -->
      <PaketRestoreRequired>false</PaketRestoreRequired>
    </PropertyGroup>

    <!-- Step 2 b detect relevant changes in project file (new targetframework) -->
    <PropertyGroup Condition=" '$(DoAllResolvedFilesExist)' != 'true' ">
      <PaketRestoreRequired>true</PaketRestoreRequired>
      <PaketRestoreRequiredReason>target-framework '$(TargetFramework)' or '$(TargetFrameworks)' files @(PaketResolvedFilePaths)</PaketRestoreRequiredReason>
    </PropertyGroup>

    <!-- Step 3 Restore project specific stuff if required -->
    <Message Condition=" '$(PaketRestoreRequired)' == 'true' " Importance="low" Text="Detected a change ('$(PaketRestoreRequiredReason)') in the project file '$(MSBuildProjectFullPath)', calling paket restore" />
    <Exec Command='$(PaketCommand) restore --project "$(MSBuildProjectFullPath)" --target-framework "$(TargetFrameworks)"' Condition=" '$(PaketRestoreRequired)' == 'true' AND '$(TargetFramework)' == '' " ContinueOnError="false" />
    <Exec Command='$(PaketCommand) restore --project "$(MSBuildProjectFullPath)" --target-framework "$(TargetFramework)"' Condition=" '$(PaketRestoreRequired)' == 'true' AND '$(TargetFramework)' != '' " ContinueOnError="false" />

    <!-- This shouldn't actually happen, but just to be sure. -->
    <PropertyGroup>
      <DoAllResolvedFilesExist>false</DoAllResolvedFilesExist>
      <DoAllResolvedFilesExist Condition="Exists(%(PaketResolvedFilePaths.Identity))">true</DoAllResolvedFilesExist>
    </PropertyGroup>
    <Error Condition=" '$(DoAllResolvedFilesExist)' != 'true' AND '$(ResolveNuGetPackages)' != 'False' " Text="One Paket file '@(PaketResolvedFilePaths)' is missing while restoring $(MSBuildProjectFile). Please delete 'paket-files/paket.restore.cached' and call 'paket restore'." />

    <!-- Step 4 forward all msbuild properties (PackageReference, DotNetCliToolReference) to msbuild -->
    <ReadLinesFromFile Condition="'@(PaketResolvedFilePaths)' != ''" File="%(PaketResolvedFilePaths.Identity)" ><!--Condition="Exists('%(PaketResolvedFilePaths.Identity)')"-->
      <Output TaskParameter="Lines" ItemName="PaketReferencesFileLines"/>
    </ReadLinesFromFile>

    <ItemGroup Condition=" '@(PaketReferencesFileLines)' != '' " >
      <PaketReferencesFileLinesInfo Include="@(PaketReferencesFileLines)" >
        <PackageName>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[0])</PackageName>
        <PackageVersion>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[1])</PackageVersion>
        <AllPrivateAssets>$([System.String]::Copy('%(PaketReferencesFileLines.Identity)').Split(',')[4])</AllPrivateAssets>
      </PaketReferencesFileLinesInfo>
      <PackageReference Include="%(PaketReferencesFileLinesInfo.PackageName)">
        <Version>%(PaketReferencesFileLinesInfo.PackageVersion)</Version>
        <PrivateAssets Condition=" ('%(PaketReferencesFileLinesInfo.AllPrivateAssets)' == 'true') Or ('$(PackAsTool)' == 'true') ">All</PrivateAssets>
        <ExcludeAssets Condition="%(PaketReferencesFileLinesInfo.AllPrivateAssets) == 'exclude'">runtime</ExcludeAssets>
        <Publish Condition=" '$(PackAsTool)' == 'true' ">true</Publish>
      </PackageReference>
    </ItemGroup>

    <PropertyGroup>
      <PaketCliToolFilePath>$(MSBuildProjectDirectory)/obj/$(MSBuildProjectFile).paket.clitools</PaketCliToolFilePath>
    </PropertyGroup>

    <ReadLinesFromFile File="$(PaketCliToolFilePath)" >
      <Output TaskParameter="Lines" ItemName="PaketCliToolFileLines"/>
    </ReadLinesFromFile>

    <ItemGroup Condition=" '@(PaketCliToolFileLines)' != '' " >
      <PaketCliToolFileLinesInfo Include="@(PaketCliToolFileLines)" >
        <PackageName>$([System.String]::Copy('%(PaketCliToolFileLines.Identity)').Split(',')[0])</PackageName>
        <PackageVersion>$([System.String]::Copy('%(PaketCliToolFileLines.Identity)').Split(',')[1])</PackageVersion>
      </PaketCliToolFileLinesInfo>
      <DotNetCliToolReference Include="%(PaketCliToolFileLinesInfo.PackageName)">
        <Version>%(PaketCliToolFileLinesInfo.PackageVersion)</Version>
      </DotNetCliToolReference>
    </ItemGroup>

    <!-- Disabled for now until we know what to do with runtime deps - https://github.com/fsprojects/Paket/issues/2964
    <PropertyGroup>
      <RestoreConfigFile>$(MSBuildProjectDirectory)/obj/$(MSBuildProjectFile).NuGet.Config</RestoreConfigFile>
    </PropertyGroup> -->

  </Target>

  <Target Name="PaketDisableDirectPack" AfterTargets="_IntermediatePack" BeforeTargets="GenerateNuspec" Condition="('$(IsPackable)' == '' Or '$(IsPackable)' == 'true') And Exists('$(MSBuildProjectDirectory)/obj/$(MSBuildProjectFile).references')" >
    <PropertyGroup>
      <ContinuePackingAfterGeneratingNuspec>false</ContinuePackingAfterGeneratingNuspec>
    </PropertyGroup>
  </Target>

  <Target Name="PaketOverrideNuspec" AfterTargets="GenerateNuspec" Condition="('$(IsPackable)' == '' Or '$(IsPackable)' == 'true') And Exists('$(MSBuildProjectDirectory)/obj/$(MSBuildProjectFile).references')" >
    <ItemGroup>
      <_NuspecFilesNewLocation Include="$(BaseIntermediateOutputPath)$(Configuration)\*.nuspec"/>
    </ItemGroup>

    <PropertyGroup>
      <PaketProjectFile>$(MSBuildProjectDirectory)/$(MSBuildProjectFile)</PaketProjectFile>
      <ContinuePackingAfterGeneratingNuspec>true</ContinuePackingAfterGeneratingNuspec>
      <UseNewPack>false</UseNewPack>
      <UseNewPack Condition=" '$(NuGetToolVersion)' != '4.0.0' ">true</UseNewPack>
      <AdjustedNuspecOutputPath>$(BaseIntermediateOutputPath)$(Configuration)</AdjustedNuspecOutputPath>
      <AdjustedNuspecOutputPath Condition="@(_NuspecFilesNewLocation) == ''">$(BaseIntermediateOutputPath)</AdjustedNuspecOutputPath>
    </PropertyGroup>

    <ItemGroup>
      <_NuspecFiles Include="$(AdjustedNuspecOutputPath)\*.nuspec"/>
    </ItemGroup>

    <Exec Command='$(PaketCommand) fix-nuspecs files "@(_NuspecFiles)" project-file "$(PaketProjectFile)" ' Condition="@(_NuspecFiles) != ''" />

    <ConvertToAbsolutePath Condition="@(_NuspecFiles) != ''" Paths="@(_NuspecFiles)">
      <Output TaskParameter="AbsolutePaths" PropertyName="NuspecFileAbsolutePath" />
    </ConvertToAbsolutePath>

    <!-- Call Pack -->
    <PackTask Condition="$(UseNewPack)"
              PackItem="$(PackProjectInputFile)"
              PackageFiles="@(_PackageFiles)"
              PackageFilesToExclude="@(_PackageFilesToExclude)"
              PackageVersion="$(PackageVersion)"
              PackageId="$(PackageId)"
              Title="$(Title)"
              Authors="$(Authors)"
              Description="$(Description)"
              Copyright="$(Copyright)"
              RequireLicenseAcceptance="$(PackageRequireLicenseAcceptance)"
              LicenseUrl="$(PackageLicenseUrl)"
              ProjectUrl="$(PackageProjectUrl)"
              IconUrl="$(PackageIconUrl)"
              ReleaseNotes="$(PackageReleaseNotes)"
              Tags="$(PackageTags)"
              DevelopmentDependency="$(DevelopmentDependency)"
              BuildOutputInPackage="@(_BuildOutputInPackage)"
              TargetPathsToSymbols="@(_TargetPathsToSymbols)"
              TargetFrameworks="@(_TargetFrameworks)"
              AssemblyName="$(AssemblyName)"
              PackageOutputPath="$(PackageOutputAbsolutePath)"
              IncludeSymbols="$(IncludeSymbols)"
              IncludeSource="$(IncludeSource)"
              PackageTypes="$(PackageType)"
              IsTool="$(IsTool)"
              RepositoryUrl="$(RepositoryUrl)"
              RepositoryType="$(RepositoryType)"
              SourceFiles="@(_SourceFiles->Distinct())"
              NoPackageAnalysis="$(NoPackageAnalysis)"
              MinClientVersion="$(MinClientVersion)"
              Serviceable="$(Serviceable)"
              FrameworkAssemblyReferences="@(_FrameworkAssemblyReferences)"
              ContinuePackingAfterGeneratingNuspec="$(ContinuePackingAfterGeneratingNuspec)"
              NuspecOutputPath="$(AdjustedNuspecOutputPath)"
              IncludeBuildOutput="$(IncludeBuildOutput)"
              BuildOutputFolder="$(BuildOutputTargetFolder)"
              ContentTargetFolders="$(ContentTargetFolders)"
              RestoreOutputPath="$(RestoreOutputAbsolutePath)"
              NuspecFile="$(NuspecFileAbsolutePath)"
              NuspecBasePath="$(NuspecBasePath)"
              NuspecProperties="$(NuspecProperties)"/>

    <PackTask Condition="! $(UseNewPack)"
              PackItem="$(PackProjectInputFile)"
              PackageFiles="@(_PackageFiles)"
              PackageFilesToExclude="@(_PackageFilesToExclude)"
              PackageVersion="$(PackageVersion)"
              PackageId="$(PackageId)"
              Title="$(Title)"
              Authors="$(Authors)"
              Description="$(Description)"
              Copyright="$(Copyright)"
              RequireLicenseAcceptance="$(PackageRequireLicenseAcceptance)"
              LicenseUrl="$(PackageLicenseUrl)"
              ProjectUrl="$(PackageProjectUrl)"
              IconUrl="$(PackageIconUrl)"
              ReleaseNotes="$(PackageReleaseNotes)"
              Tags="$(PackageTags)"
              TargetPathsToAssemblies="@(_TargetPathsToAssemblies->'%(FinalOutputPath)')"
              TargetPathsToSymbols="@(_TargetPathsToSymbols)"
              TargetFrameworks="@(_TargetFrameworks)"
              AssemblyName="$(AssemblyName)"
              PackageOutputPath="$(PackageOutputAbsolutePath)"
              IncludeSymbols="$(IncludeSymbols)"
              IncludeSource="$(IncludeSource)"
              PackageTypes="$(PackageType)"
              IsTool="$(IsTool)"
              RepositoryUrl="$(RepositoryUrl)"
              RepositoryType="$(RepositoryType)"
              SourceFiles="@(_SourceFiles->Distinct())"
              NoPackageAnalysis="$(NoPackageAnalysis)"
              MinClientVersion="$(MinClientVersion)"
              Serviceable="$(Serviceable)"
              AssemblyReferences="@(_References)"
              ContinuePackingAfterGeneratingNuspec="$(ContinuePackingAfterGeneratingNuspec)"
              NuspecOutputPath="$(AdjustedNuspecOutputPath)"
              IncludeBuildOutput="$(IncludeBuildOutput)"
              BuildOutputFolder="$(BuildOutputTargetFolder)"
              ContentTargetFolders="$(ContentTargetFolders)"
              RestoreOutputPath="$(RestoreOutputAbsolutePath)"
              NuspecFile="$(NuspecFileAbsolutePath)"
              NuspecBasePath="$(NuspecBasePath)"
              NuspecProperties="$(NuspecProperties)"/>
  </Target>
  <!--/+:cnd:noEmit-->
</Project>


text:
version: '3'

services:
  server:
    profiles: ["test", "production"]
    build: .
    image: subterfuge_server
    depends_on:
      - db
    volumes:
      - ".:/var/www"
    ports:
      - 5295:5295
    environment:
      - ASPNETCORE_URLS=http://*:5295
      - DOTNET_ENVIRONMENT=Docker
      - ASPNETCORE_ENVIRONMENT=Docker
  db:
    image: "mongo:5.0-rc"
    command: --auth
    volumes:
      - "./mongodb:/data/db"
    ports:
      - 27017:27017
    environment:
      - MONGO_INITDB_ROOT_USERNAME=user
      - MONGO_INITDB_ROOT_PASSWORD=password
      - MONGO_INITDB_DATABASE=subterfugeDb
  server_test:
    profiles: ["test"]
    build:
      context: .
      target: test
    depends_on:
      - db
      - server
    environment:
      - ASPNETCORE_ENVIRONMENT=Docker

volumes:
  db: {  }

repo_name: Subterfuge-Revived/Remake-Core

repo_language: C#


text:
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29215.179
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Engine", "Engine", "{B0FD622D-BA4B-4B31-B1BF-40736F911E89}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeCore", "Core\SubterfugeCore\SubterfugeCore.csproj", "{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeCoreTest", "Core\SubterfugeCoreTest\SubterfugeCoreTest.csproj", "{C8124D15-E4F5-4799-AB34-7A2E54552108}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Server", "Server", "{BF8D86D2-5F72-4559-90EC-7A249CC25B59}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Models", "Core\Models\Models.csproj", "{98D9890E-D1CC-4028-AB07-4815D031349F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeRestApiServer", "Server\SubterfugeRestApiServer\SubterfugeRestApiServer.csproj", "{8E861222-94AC-4048-B264-83CF345CB2C3}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeRestApiClient", "Server\SubterfugeRestApiClient\SubterfugeRestApiClient.csproj", "{96D25C5A-509A-427C-8222-A25B21A9852F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeRestApiServerTest", "Server\SubterfugeRestApiServerTest\SubterfugeRestApiServerTest.csproj", "{C8B467E0-97E0-4475-97BE-68BA873F71B1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SubterfugeDatabaseProvider", "Server\SubterfugeDatabaseProvider\SubterfugeDatabaseProvider.csproj", "{F571DEBD-4EB8-4E95-BC19-A99B570A5650}"
EndProject
Global
	GlobalSection(SharedMSBuildProjectFiles) = preSolution
		SubterfugeRemake.Shared\SubterfugeRemake.Shared.projitems*{40bad8d2-6233-4756-9c77-74ed117c91f1}*SharedItemsImports = 4
		SubterfugeRemake.Shared\SubterfugeRemake.Shared.projitems*{9b3772b5-2508-4bf3-aec2-742206e648a8}*SharedItemsImports = 4
		SubterfugeRemake.Shared\SubterfugeRemake.Shared.projitems*{a0cdbd0e-3a41-42b7-9425-a838bc2c7383}*SharedItemsImports = 13
	EndGlobalSection
	GlobalSection(SolutionConfigurationPlatforms) = preSolution
		Ad-Hoc|Any CPU = Ad-Hoc|Any CPU
		Ad-Hoc|iPhone = Ad-Hoc|iPhone
		Ad-Hoc|iPhoneSimulator = Ad-Hoc|iPhoneSimulator
		AppStore|Any CPU = AppStore|Any CPU
		AppStore|iPhone = AppStore|iPhone
		AppStore|iPhoneSimulator = AppStore|iPhoneSimulator
		Debug|Any CPU = Debug|Any CPU
		Debug|iPhone = Debug|iPhone
		Debug|iPhoneSimulator = Debug|iPhoneSimulator
		Release|Any CPU = Release|Any CPU
		Release|iPhone = Release|iPhone
		Release|iPhoneSimulator = Release|iPhoneSimulator
	EndGlobalSection
	GlobalSection(ProjectConfigurationPlatforms) = postSolution
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|iPhone.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|Any CPU.Build.0 = Release|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|iPhone.ActiveCfg = Release|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|iPhone.Build.0 = Release|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|iPhone.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|Any CPU.Build.0 = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|iPhone.ActiveCfg = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|iPhone.Build.0 = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{C8124D15-E4F5-4799-AB34-7A2E54552108}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|iPhone.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|Any CPU.Build.0 = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|iPhone.ActiveCfg = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|iPhone.Build.0 = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{98D9890E-D1CC-4028-AB07-4815D031349F}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
		{8E861222-94AC-4048-B264-83CF345CB2C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{8E861222-94AC-4048-B264-83CF345CB2C3}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|iPhone.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|Any CPU.Build.0 = Release|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|iPhone.ActiveCfg = Release|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|iPhone.Build.0 = Release|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{96D25C5A-509A-427C-8222-A25B21A9852F}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|iPhone.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|Any CPU.Build.0 = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|iPhone.ActiveCfg = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|iPhone.Build.0 = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{C8B467E0-97E0-4475-97BE-68BA873F71B1}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|Any CPU.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|Any CPU.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Ad-Hoc|iPhoneSimulator.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|Any CPU.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|Any CPU.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|iPhone.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.AppStore|iPhoneSimulator.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|Any CPU.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|iPhone.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|iPhone.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|Any CPU.ActiveCfg = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|Any CPU.Build.0 = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|iPhone.ActiveCfg = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|iPhone.Build.0 = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
	EndGlobalSection
	GlobalSection(SolutionProperties) = preSolution
		HideSolutionNode = FALSE
	EndGlobalSection
	GlobalSection(NestedProjects) = preSolution
		{48D0B106-36E9-49A8-9BA6-6BB2AA97B58C} = {B0FD622D-BA4B-4B31-B1BF-40736F911E89}
		{C8124D15-E4F5-4799-AB34-7A2E54552108} = {B0FD622D-BA4B-4B31-B1BF-40736F911E89}
		{98D9890E-D1CC-4028-AB07-4815D031349F} = {B0FD622D-BA4B-4B31-B1BF-40736F911E89}
		{8E861222-94AC-4048-B264-83CF345CB2C3} = {BF8D86D2-5F72-4559-90EC-7A249CC25B59}
		{96D25C5A-509A-427C-8222-A25B21A9852F} = {BF8D86D2-5F72-4559-90EC-7A249CC25B59}
		{C8B467E0-97E0-4475-97BE-68BA873F71B1} = {BF8D86D2-5F72-4559-90EC-7A249CC25B59}
		{F571DEBD-4EB8-4E95-BC19-A99B570A5650} = {BF8D86D2-5F72-4559-90EC-7A249CC25B59}
	EndGlobalSection
	GlobalSection(ExtensibilityGlobals) = postSolution
		SolutionGuid = {2CE4380E-1D17-4F42-8398-6FF7F6F14244}
	EndGlobalSection
EndGlobal


text:
FROM mcr.microsoft.com/dotnet/aspnet:7.0 AS base
WORKDIR /app
EXPOSE 80

FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build
WORKDIR /app
COPY ./Server/SubterfugeRestApiServer/SubterfugeRestApiServer.csproj ./Server/SubterfugeRestApiServer/SubterfugeRestApiServer.csproj
RUN dotnet restore ./Server/SubterfugeRestApiServer/SubterfugeRestApiServer.csproj
COPY . .
RUN dotnet build ./Server/SubterfugeRestApiServer/SubterfugeRestApiServer.csproj -c Release -o /app/build

FROM build as test
WORKDIR /app
CMD ["dotnet", "test", "./Server/SubterfugeRestApiServerTest/SubterfugeRestApiServerTest.csproj"]

FROM build AS publish
RUN dotnet publish ./Server/SubterfugeRestApiServer/SubterfugeRestApiServer.csproj -c Release -o /app/publish

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
COPY ./Server/SubterfugeRestApiServer/appsettings.Docker.json ./appsettings.Docker.json
ENTRYPOINT ["dotnet", "SubterfugeRestApiServer.dll", "--launch-profile", "Docker"]


text:
[![languages](https://img.shields.io/github/languages/top/Subterfuge-Revived/Remake-Core)]()
[![code-size](https://img.shields.io/github/languages/code-size/Subterfuge-Revived/Remake-Core)]()
[![commit-activity](https://img.shields.io/github/commit-activity/y/Subterfuge-Revived/Remake-Core)](https://github.com/Subterfuge-Revived/Remake-Core/pulse/yearly)
[![license](https://img.shields.io/github/license/Subterfuge-Revived/Remake-Core)](LICENSE)
[![discord](https://img.shields.io/discord/617149385196961792)](https://discord.gg/GNk7Xw4)
[![issues](https://img.shields.io/github/issues/Subterfuge-Revived/Remake-Core)](https://github.com/Subterfuge-Revived/Remake-Core/issues?q=is%3Aopen)
[![issues-closed-raw](https://img.shields.io/github/issues-closed/Subterfuge-Revived/Remake-Core)](https://github.com/Subterfuge-Revived/Remake-Core/issues?q=is%3Aclosed+)

# Remake-Core

### [View the API Documentation](https://subterfuge-revived.github.io/Remake-Core/index.html)

This repository is a combination of the class library which runs the game, as well as the game server and client libraries.

For additional information on the game server, view the readme in the `Server` directory.

## Setup

### Required Dependencies

Ensure that you have the following programs installed:

- A C# IDE like [Jetbrains Rider](https://www.jetbrains.com/rider/) or [Visual Studios Community 2019](https://visualstudio.microsoft.com/)
- [.NET standard 2.0 framework](https://dotnet.microsoft.com/download/dotnet-core/2.0) and [.Net Core 7.0](https://dotnet.microsoft.com/download/dotnet/7.0)
- [Git](https://git-scm.com/downloads)

For local server development:

- [Docker](https://docs.docker.com/get-docker/)
- [Docker Compose](https://docs.docker.com/compose/install/)

Note: Docker Desktop (available on [Windows](https://docs.docker.com/desktop/install/windows-install/), [Mac](https://docs.docker.com/desktop/install/mac-install/), and [Linux](https://docs.docker.com/desktop/install/linux-install/))
includes Docker Compose by default. If this is your first installation of Docker, I would recommend just installing Docker Desktop.
Docker Desktop provides a nice GUI that shows you all of your images, running containers, volumes, etc. so that you don't have to remember or worry about any docker CLI commands.

### Configuring the project

1. [Fork this repository](https://github.com/Subterfuge-Revived/Remake-Core/fork)

2. Clone this repository:

```
git clone git@github.com:Subterfuge-Revived/Remake-Core.git
```

3. Add your fork as a remote:

```
cd Remake-Core
git remote add <yourName> <URL to your fork repository>
```

5. Using your IDE, open the `SubterfugeRemake.Shared.sln` file. This will open the project within your IDE.

6. To verify things worked, run the unit tests. Expand the `Engine` folder and right click on `SubterfugeCoreTest` and click "Run unit tests" (or similar).
If your IDE does not have the ability to do this, the following command can be executed to run the tests instead:

```
dotnet test Core/SubterfugeCoreTest
```

7. Watch the tests pass!

Note: The `SubterfugeRestApiServerTest` project requires both the database and the server to be running in order to pass.
Please see the [Server readme](Server/README.md) for more information about the server.

# Repositories

## Engine

#### [Models](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Core/Models)

The Models project is a class library that contains C# classes that are shared between the server and the client libraries.
This project mainly contains Server-client classes that are shared between one another and are generally used to produce network calls, or are class objects that can be sereialized from the server's response.
These are mainly networking classes and should be pure classes with only fields and no methods.

#### [SubterfugeCore](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Core/SubterfugeCore)

The bread and butter. This project contains all of the game logic. Generating the game state, loading a game from the server, creating a new game, launching a sub, specialists, combats, outposts. Anything in-game related is done here.
This library is used in Unity to be able to determine what the current state of a game is, and also used to load a gamestate from the network. This project is also used on the server side to validate network requests, verify submitted events,
and perform other validation checks, for example, if there is a winner of the game.

### [SubterfugeCoreTest](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Core/SubterfugeCoreTest)

Unit tests for Subterfuge Core. This project is purely for unit testing the main game logic. Unit tests ensure that upon future updates, existing code and functionality is not broken when new changes get added to the game.
These unit tests get executed on every merge request and are REQUIRED to pass before a merge request can be accepted. Ensure that any new code you write gets a unit test created for it.

## Server

#### [SubterfugeDatabaseProvider](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Server/SubterfugeDatabaseProvider)

A class library that creates database models for [MongoDB](https://www.mongodb.com/), and sets up all of the logic for MongoDB around the database models.
The data here is all encapsulated by interface methods which make it easy to swap out our database provider with another database if we chose to in the future.
Writing to and reading from the database is done here.

#### [SubterfugeRestApiClient](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Server/SubterfugeRestApiClient)

A client repository for sending API requests to the server. This client library is used to perform integration tests against the server, but also used by the unity client to make interacting with the server easier.

#### [SubterfugeRestApiServer](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Server/SubterfugeRestApiServer)

The subterfuge game server. This project integrates database storage with incoming client API requests to facilitate multiplayer play.
The server stores and processes information like: Creating game lobbies, joining game lobbies, submitting game events, adding friends, sending chat messages, and more.

#### [SubterfugeRestApiServerTest](https://github.com/Subterfuge-Revived/Remake-Core/tree/master/Server/SubterfugeRestApiServerTest)

Unit tesets for the Subterfuge Server. This project performs integration tests against the SubterfugeServer and requires a running database. This project tests various server endpoints and validates
that all of the required server functionality can be performed as expected.

# Using the Core Libraries

The unity application makes use of the `Engine` projects. Specifically `SubterfugeCore` which contains a class library with all of the primary game logic.

Once the `SubterfugeCore` project is build, a `dll` file is generated which needs to be included in the unity editor (the unity repository has this file committed to ensure devs don't need to have both repos running).

However, when working with the `dll`, it is a good idea to view the [API documentation on the class library here](https://subterfuge-revived.github.io/Remake-Core/index.html) to understand how to use classes that are avaliable.

For example, how to load a game, parse a gamestate from the server, launch a sub, alter the time machine, etc.


text:
# Description

<!--
Please include a summary of the change and which issue is fixed.
Please also include relevant motivation and context. This can be helped by linking to any related issue (ex: Fixes #1).
Be as detailed as possible and be sure to indicate how this change will effect downstream users.

Also list any new dependencies/packages that are required for this change.
-->

# Versioning

Previous Version:
Next Version Number:

 - [ ] I have updated the README to reflect the new version number
 - [ ] When I publish a release I will append the version number to the dll's name

# Type of change

<!-- Please select options that are relevant. -->

### CLI
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update
- [ ] New dependencies/packages

### Core
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update
- [ ] New dependencies/packages

# Testing

<!-- Describe the tests that you ran to verify your changes -->

- [ ] I have created automated tests for any new features
- [ ] All automated tests pass
- [ ] I have performed manual tests

# Checklist:

<!-- Please make sure the following have been performed. -->
<!-- If they have not yet been performed, leave them unchecked (and/or) title your PR with "WIP: ". -->

- [ ] I have performed a self-review of my own code
- [ ] I have commented my code according to C# standards
- [ ] I have made corresponding changes to the README (if required)
- [ ] I have added/updated articles in the documentation
- [ ] My changes generate no new warnings

<!--
Does this PR include breaking changes to downstream modules?
The backend and Unity repositories make use of the DLL that is generated by this repository.
If any breaking changes are made, ensure that the backend and unity developers are aware of the changes.
-->

# Questions / Discussion

<!-- Any questions you are still wondering about or discussions to be had about the changes.
You can also include specific areas/files you would like reviewed or commented on. -->